-
Notifications
You must be signed in to change notification settings - Fork 317
fix logger order #102
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
fix logger order #102
Conversation
When redux dispatch an action, after calling the reducer, the listeners will be called. If the listener dispatch a new action, redux allow it, but the order of the log will in reverse. this PR fix the order in that case.
Can you make a demo, please? |
OK, but it may take some time because of my bad network~~ |
I'll try tomorrow. |
I can confirm the issue is real. Listeners subscribed to redux store are executed synchronously, so running |
We are also seeing this, @theaqua would you like a demo still? If so I can put one together. |
@bitfrost yes please. I don't have enough time :( |
Here you go: https://github.com/bitfrost/logging-in-wrong-order/blob/master/index.es6 open index.html and view the logger output and compile it with console.log output from the 1 reducer. |
# Conflicts: # src/index.js
I has merged conflict. |
@jetzhliu of course :) Thanks! |
Released in 2.4.0. |
When redux dispatch an action, after calling the reducer, the listeners
will be called. If the listener dispatch a new action, redux allow it,
but the order of the log will in reverse.
this PR fix the order in that case.