Skip to content

Releases: ducksboard/backbone.subroute

BaseURLs

03 Nov 10:41
Compare
Choose a tag to compare

Add the option to have base URLs for subrouters

Lazy Duck

22 May 09:55
Compare
Choose a tag to compare
Provide a toggle to avoid triggering subroute in constructor

Backbone routes are not triggered on setup, but after Backbone.History
is started. Subroutes, on the other hand, try to trigger during their
setup (in the constructor). This breaks use cases where all the routes
are expected to be defined before starting the history mechanism.

The current patch adds a new option, 'immediate', that toggles this
initial triggering of subroutes. The default, to be consistent with the
current code, is to trigger them immediately, but this behaviour can be
disabled by passing 'false'.