Skip to content

Instantly share code, notes, and snippets.

@a-ignatov-parc
Created February 21, 2012 06:34
Show Gist options
  • Save a-ignatov-parc/1874347 to your computer and use it in GitHub Desktop.
Save a-ignatov-parc/1874347 to your computer and use it in GitHub Desktop.
for (var route in this.routes) {
var regData = reg.exec(route);
if (regData && !bindedList[regData[0]]) {
this.bind('route:' + regData[0], function() {
this.context.trigger('route.changed', this.route);
}.bind({
context: this,
route: regData[0]
}));
bindedList[regData[0]] = YES;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment