Closed Kai-W closed 2 months ago
I've updated from resium@1.16.1 to resium@1.17.1 then I get a similar issue.
In strict mode, this occurs.
I'm not using MaterialUI Dialog but a custom tailwind component with an absolute div.
i tried to reproduce the problem without Material UI: It seems the problem occures if there is a change in the component hierarchy https://codesandbox.io/p/sandbox/trusting-ride-v7jqxz?file=%2Fsrc%2FApp.tsx%3A87%2C22
The new Resium Version seems to fix the duplication bug but moving the viewer to the bounding box works for the first render but breaks after a recreation of the viewer. https://codesandbox.io/p/devbox/elastic-thunder-wvx2n3?file=%2Fsrc%2FApp.tsx%3A20%2C
i opend a new issue https://github.com/reearth/resium/issues/661 for the new Problem. The duplciate Cesium render seems to be fixed
I have an app where Cesium/Resium is used to rendere 3DTilesets on an Openstreetmap in a MaterialUI Dialog. With React StrictMode enabled the first component doesn't get unmounted properly. https://codesandbox.io/p/sandbox/magical-christian-fqsxd6?file=%2Fsrc%2FApp.tsx%3A64%2C23
Inside the Dialog there are 2 instances of Cesium. First a broken one and below it is a second working Cesium instance![image](https://github.com/reearth/resium/assets/1429148/84b40c27-582e-4f85-a8b1-9f59f057b073)
Tested on Windows with Chrome, Edge and Firefox.
Wierdly this only happens inside a Mui Dialog. Without the Dialog component Resium unmounts as expected