Changelog
3.0.0
routr
uses native URLSearchParams
instead of query-string
to parse query strings. As a consequence, parsing ?foo
will result in { foo: '' }
as specified in the WHATWG spec instead of { foo: null }
as query-string
would do. Also, URLSearchParams
is not available in older browsers (noticeably IE11). If you need to support them, you can either add a URLSearchParams
polyfill or inject query-string
when instantiating routr
:router = new Routr(routes, {
queryLib: require('query-string'),
});
path-to-regexp
to its latest version