You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Problem:
Now, when i generate a page which contains of hundreds of nodes (even more), whenever i start to copy some nodes on craftJS or setting new props in a node, i will wait for maybe 5-10 seconds.
Why:
I think it is because of craftJS uses immer.js and listen on the state.nodes, even a tinny change will cause the whole Frame.tsx re-render from top to end, it seems like a recursion. And also, these events will connect again during this rendering.
Question:
I am totally agree that it is a open-source project and us should not raise any requirements. But i still want to ask how can i avoid the biggest rendering cost or if we can re-build the structure to improve that ?
My idea:
I am impacted from React Fiber, and if we can also build two tree (one memory, one current), and then diff it so that we just need to care about those changing part?
The text was updated successfully, but these errors were encountered:
Problem:
Now, when i generate a page which contains of hundreds of nodes (even more), whenever i start to copy some nodes on craftJS or setting new props in a node, i will wait for maybe 5-10 seconds.
Why:
I think it is because of craftJS uses immer.js and listen on the state.nodes, even a tinny change will cause the whole Frame.tsx re-render from top to end, it seems like a recursion. And also, these events will connect again during this rendering.
Question:
I am totally agree that it is a open-source project and us should not raise any requirements. But i still want to ask how can i avoid the biggest rendering cost or if we can re-build the structure to improve that ?
My idea:
I am impacted from React Fiber, and if we can also build two tree (one memory, one current), and then diff it so that we just need to care about those changing part?
Problem:
Now, when i generate a page which contains of hundreds of nodes (even more), whenever i start to copy some nodes on craftJS or setting new props in a node, i will wait for maybe 5-10 seconds.
Why:
I think it is because of craftJS uses immer.js and listen on the state.nodes, even a tinny change will cause the whole Frame.tsx re-render from top to end, it seems like a recursion. And also, these events will connect again during this rendering.
Question:
I am totally agree that it is a open-source project and us should not raise any requirements. But i still want to ask how can i avoid the biggest rendering cost or if we can re-build the structure to improve that ?
My idea:
I am impacted from React Fiber, and if we can also build two tree (one memory, one current), and then diff it so that we just need to care about those changing part?
The text was updated successfully, but these errors were encountered: