@@ -304,17 +304,24 @@ where you can get it now if you are **not** a route component (`this.context`).
304
304
| ` getPathname() ` | ` location.pathname ` |
305
305
| ` getQuery() ` | ` location.search ` |
306
306
| ` getQueryParams() ` | ` location.query ` |
307
- | ` isActive(to, params, query) ` | ` history.isActive(pathname, query, onlyActiveOnIndex ) ` |
307
+ | ` isActive(to, params, query) ` | ` history.isActive(pathname, query, indexOnly ) ` |
308
308
309
309
Note not all ` State ` functionality can be accessed via context in v1.0.
310
310
For example, ` params ` is not available via context.
311
311
312
312
### Scrolling
313
313
314
- In 0.13.x we had a couple of implementations to restore scroll position,
315
- we've realized that we can build a better implementation on top of the
316
- router and will be doing that very soon, before the 1.0 final release,
317
- but it doesn't need to be baked into routing like it was before.
314
+ We're developing scroll behaviors separately in the
315
+ [ ` scroll-behavior ` ] ( https://github.com/rackt/scroll-behavior )
316
+ library until we have a stable, robust implementation that we're happy with.
317
+ Currently, scroll behaviors are exposed there as history enhancers:
318
+
319
+ ``` js
320
+ import createHistory from ' history/lib/createBrowserHistory'
321
+ import useScroll from ' scroll-behavior/lib/useStandardScroll'
322
+
323
+ const history = useScroll (createHistory)()
324
+ ```
318
325
319
326
### ` willTransitionTo ` and ` willTransitionFrom `
320
327
0 commit comments