Open marc2332 opened 8 months ago
This is expected behavior. VNodes currently implement partialeq by pointer. They could implement a deeper partialEq if the pointers are different, but the current behavior is pretty similar to what you would get with borrowed props with an Element in 0.4
🏃
We could attempt to diff them with a slightly deeper comparison
Problem
When a component re runs and is passing an
Element
to another component, this other component will always rerun, because Dioxus can't seem to be able to memoizeElement
s.Steps To Reproduce
Steps to reproduce the behavior:
Expected behavior
Only
println!("Why am I running?");
should run when the parent component re-runs if the passed children are still the same, right?Screenshots
If applicable, add screenshots to help explain your problem.
Environment: