describe dat data-no-routing attr (#474)

This commit is contained in:
Irina Shestak
2017-04-13 16:41:09 +02:00
committed by Yoshua Wuyts
parent b5ed2f3828
commit 2faba85b84
+4
View File
@@ -282,6 +282,10 @@ By default we also catch and match all `<a href="">` clicks against the router.
This can be disabled by setting `opts.href` to `false` in the constructor.
Routing via `pushState` will not work until the `DOMContentLoaded` event has been fired.
If you need choo to ignore a particular route, you can add `data-no-routing`
attribute with `<a href="" data-no-routing>`. This is especially useful for
directing outside the choo app.
Querystrings (`?foo=bar`) are ignored when matching routes. They should be
extracted from the `window.location` object on render events, from either a
custom event listener or the matched views.