ready

  • function
can.route.ready  

Initialize can.route.

can.route.ready()

Sets up the two-way binding between the hash and the can.route observable map and sets the can.route map to its initial values.

Returns

{can.route(template, defaults)}

The can.route object.

Use

After setting all your routes, call can.route.ready().

can.route("overview/:dateStart-:dateEnd");
can.route(":type/:id")
can.route.ready()