-
Notifications
You must be signed in to change notification settings - Fork 330
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Execute action functors by wrapping them in setTimeout. #23
Conversation
I put setTimeout as a dependency injection via |
I'd rather avoid adding dependencies to the project (much like we did earlier with removing lodash as dependency). Even though nextTick is a small library, it seems unneccesary for the scope of our project. I believe it's better in this case, for the sake of smaller footprint for browsers, to let the user choose to inject nextTick themselves through set nextTick and have setTimeout be the default implementation. Also add documentation on the README on how to inject nextTick. |
Alternatively we could try to configure browserify to ignore the nextTick when building, and have Reflux use setTimeout default implementation if nextTick dependency is missing. Not sure how to do that though, I thought I saw some project doing this. The goal is that the npm package should contain the nextTick package, while the bower component will have it optional. |
I don't follow. The I amended the commit. |
Because the user might be using the polyfill in their own build. No need to have it twice, once in their own project and second from our project. It's just unnecessary overhead. |
Fine by me. Just leave it [the module] out. |
All right! |
I'll review the tests later tonight before merging. |
Renamed all instances of |
Turns out The best option is a polyfilled Reason: http://www.nczonline.net/blog/2013/07/09/the-case-for-setimmediate/
Updated README on this. |
Execute action functors by wrapping them in setTimeout.
Closes #22.