-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Canvas child is placed outside the DOM tree making it difficult to use React context #114
Comments
this is a problem with react itself, all reconcilers suffer from it, here's a similar issue for react-konva: konvajs/react-konva#188 . you can either just reflect the context inside the canvas, which will work: konvajs/react-konva#188 (comment) or use a state manager that isn't reliant on context: https://github.com/react-spring/zustand |
ghost
closed this as completed
Jun 13, 2019
This was referenced Jun 15, 2019
You could write a bridge to pass the context: |
vorth
added a commit
to vorth/vzome
that referenced
this issue
Nov 29, 2019
Clicking on any ball toggles the working plane. I had to give up on using redux-bundler connect() inside the graphic components, due to a known issue with context and reconcilers: pmndrs/react-three-fiber#114 (comment)
This issue was closed.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If I wrap the ... section of my code in some React context provider, the elements in Canvas do not have access to the context as I'd have expected. I checked the virtual DOM on dev tools, and turns out the children of Canvas is just placed outside of the tree. Is that normal? If yes, how do I make my context available inside Canvas?
The text was updated successfully, but these errors were encountered: