canjs / can-route

Observable front-end application routing for CanJS.
https://canjs.com/doc/can-route.html
MIT License
10 stars 4 forks source link

Add a warning when .data is set after .register() is called in can-route #254

Closed chasenlehara closed 4 years ago

chasenlehara commented 4 years ago

.register() will read .data when it’s called, so setting .data later may have unintended consequences.

Suggestions welcome on the warning’s wording and if we should add more docs around this.