Skip to content

Instantly share code, notes, and snippets.

@mtrpcic
Created December 11, 2012 18:03
Show Gist options
  • Save mtrpcic/4260693 to your computer and use it in GitHub Desktop.
Save mtrpcic/4260693 to your computer and use it in GitHub Desktop.
var routes = {
"/users": function(){},
"/users/:id": function(){},
"/pages": function(){}
}
for(key in routes){
Path.map(key).to(routes[key]);
}
@rrmdn
Copy link

rrmdn commented Dec 19, 2012

thanks for this example,i'll use this example as my router in my page

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment