State Management Without Restarting Render Loop #2080
-
What's the best way to stop an RTF component from rerendering (i.e. restarting the render loop) after state change? I noticed that the RTF examples all return the Canvas component in the App.js, but what if I want to integrate the Canvas in a larger ensemble? When I manually create a component rendering to the canvas (in vanilla React), I usually wrap everything in Or is the Canvas always meant to wrap the whole app? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 6 replies
-
Canvas is your entry point for three, you can use that alongside other DOM elements. I'm not sure what you mean by restarting render loop, useFrame subscriptions live outside of react. |
Beta Was this translation helpful? Give feedback.
Canvas is your entry point for three, you can use that alongside other DOM elements.
I'm not sure what you mean by restarting render loop, useFrame subscriptions live outside of react.