Skip to content

Instantly share code, notes, and snippets.

@zeroeth
Last active December 31, 2015 01:29
Show Gist options
  • Select an option

  • Save zeroeth/7914290 to your computer and use it in GitHub Desktop.

Select an option

Save zeroeth/7914290 to your computer and use it in GitHub Desktop.
Backbone.js missing route catch all
Backbone.Router.extend({
routes: {
"": "showWelcome",
"other": "showOther",
"*nomatch": "notFound",
},
notFound: function() {
console.info("Route not found:", arguments);
},
/* ... */
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment