Quantcast
Channel: JavaScriptMVC Forum
Viewing all articles
Browse latest Browse all 3491

Re : CanJS Route Not Working When Pressing The Browser's Back Button

$
0
0
can.route is working just fine, The 'controller1 init' is rendered briefly when the Control is created, but then can.route.ready(true) quickly fires the initial route change event and that HTML is replaced by the 'route' handler to be 'controller1 route' (had to fix this since it just receives data as a param and no element).

So your history starts with the empty route and if you navigate forward and the back, you can't go back past the empty route (start of the history).

Here's a working fiddle: http://jsfiddle.net/donejs/5hBZ4/1/

Viewing all articles
Browse latest Browse all 3491

Trending Articles