Closed cvan closed 9 years ago
The issue is that router.trigger
wasn't initially meant to trigger more than 1 event. The reason this was believed was because the JavaDoc was copied from router.bind
, but the functionality did not follow. So that's my fault. That's what I get for copying and pasting JavaDoc! :]
Thanks for bringing this up, it also made me realize that there was a typo in README.md.
you don't want to allow router.trigger
to trigger multiple events? could be be nice
Generally, a developer should be binding to multiple, but triggering once. This prevents event emitters from getting out of hand. Barring firing multiple events for compatibility issues, the app only needs to be emitting events once per line. If you really need to, you can call it multiple times. router.trigger().trigger();
yep, that's how I'm doing it now - okay, no worries
although the docs/comments suggest it can be done, multiple events cannot be called when separated by a space.