cherrytree
Advanced tools
Changelog
v2.0.0-rc2
router.generate('/a/b/c', {}, { id: 'def', foo: 'bar', baz: undefined })
results in /a/b/c?id=def&foo=bar
now as in the older versions of cherrytree.Changelog
v2.0.0-rc1
Breaking changes:
.index
treatment has been removed. Previously, if the route name ended with .index
, the path was automatically set to ''. Now, such path will default to 'index' as with all other routes. Set path: ''
on your index routes when upgrading.abstract: true
was introduced for making non leaf routes non routable. This also solves the problem where using path: ''
would result in multiple routes with the same path.paramNames
array (e.g. ['id', 'filter']) was replaced with params
object (e.g. {id: 1, filter: 'foo'}) in the route descriptor on the transition object.ancestors
attribute was removed from the route descriptor.history
and memory
locations has been simplified. Previously, you'd need to pass new MemoryLocation(path)
when calling listen
. Now, specify the location to use with location: 'memory'
when creating the router and pass the path when calling listen
.qs
module was removed from dependencies and was replaced with a tiny, simple query string parser. This can be sufficient for a lot of applications and saves a couple of kilobytes. If you want to use qs
or any other query parsing module, pass it as qs: require('qs')
option to the router.map
, reduce
and forEach
need to be used now.reset
was removed from the router.New features:
Under the hood improvements:
co
with babel-creed-async
in testslodash
Documentation:
docs/api.md
fileChangelog
v2.0.0-alpha.12
Changelog
v2.0.0-alpha.11
transition.redirectTo
so that middleware could initiate redirects without having the routerChangelog
v2.0.0-alpha.10
Changelog
v2.0.0-alpha.9
window
path
TransitionRedirected
error - the err.nextPath
is now available)Changelog
v2.0.0-alpha.8
Changelog
v2.0.0-alpha.7
pushState: true
and root !== '/'