-
Notifications
You must be signed in to change notification settings - Fork 46.8k
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
react-debug-tools accepts currentDispatcher ref as param #14556
react-debug-tools accepts currentDispatcher ref as param #14556
Conversation
Because I believe I can hack this in by comparing |
Can we make |
Yes, I can make this change. It seems a bit weird to me though because if you forget to inject a value in the DevTools use case, you'll be reading/writing from the wrong dispatcher ref. I see the usefulness for this though in cases like you describe. Edit Although I guess in this case, React would throw an error right away so at least it wouldn't be a silent failure. Should we catch and re-throw a more meaningful error in this case? |
ce0f030
to
721f16c
Compare
Okay. Back to you @sebmarkbage |
Details of bundled changes.Comparing: b4ad8e9...721f16c react-debug-tools
Generated by 🚫 dangerJS |
In support of facebook/react-devtools#1272.
The
react-debug-tools
package can't import shared internals because it isn't bundled along with the application. Instead it needs to accept those internals from DevTools, which gets them from the renderer (#14550).