Closed gaboesquivel closed 9 years ago
The route priority is based on when the route is created ascending from sooner to later. For example, if you had your first route after your second route, it will have a lower priority.
// First priority
router.get('/:page?', handler);
// Third priority
setTimeout(function(){
router.get('/async/:page?', handler);
}, 2000);
// Second priority
router.get('/doSomethingElse', doSomethingElse);
I would like to set priority for conflicting routes like these
problem is doSomethingElse is never called. so I have to check params inside my other route. It would be nice to be able specify route priority.