tmeasday / meteor-router

MIT License
366 stars 76 forks source link

Add route abort feature when beforeRouting returns false #105

Closed lukepur closed 11 years ago

lukepur commented 11 years ago

This pull request adds the functionality whereby returning false in the beforeRouting callback will prevent the route from occurring.

This is useful, for example, if one wants to detect unsaved changes and present a modal dialog to allow the route to abort if need be.

Test included.

tmeasday commented 11 years ago

Thanks!