Please avoid duplicates
Language and Compiler
Vanilla JavaScript
What environment are you using?
Local Development Server
When does your problem occur?
When the Unity Component unmounts
What does your problem relate to?
The problem seems React related
React-Unity-WebGL Version
10.1.6
React Version
17.0.2
Unity Version
6000.2.5
What happened?
Hello
My situation is as follows:
The version of Unity I'm using is 6000.2.5. To export WebGL, it can only be loaded via HTTPS. The loading process is normal, but when uninstalling the Unity browser, it becomes unresponsive. The probability of this problem occurring is 90%. I read https://react-unity-webgl.dev/docs/api/unload (Unloading the Unity Application) The original text reads: "Since React Unity WebGL version 10, calling the unload function is no longer necessary to unmount the Unity Application. The Unity Application will automatically be unmounted when the component is removed from the DOM. However, if you want to unload the Unity Application manually, you can still use the unload function. But be aware that this is not necessary in most cases." I tried including the unload code and not including it, but it still caused the browser to become unresponsive. I have tested the code according to the API, and the unresponsive situation still occurred.
Reproducible test case
No response
Would you be interested in contributing a fix?
Please avoid duplicates
Language and Compiler
Vanilla JavaScript
What environment are you using?
Local Development Server
When does your problem occur?
When the Unity Component unmounts
What does your problem relate to?
The problem seems React related
React-Unity-WebGL Version
10.1.6
React Version
17.0.2
Unity Version
6000.2.5
What happened?
Hello
My situation is as follows:
The version of Unity I'm using is 6000.2.5. To export WebGL, it can only be loaded via HTTPS. The loading process is normal, but when uninstalling the Unity browser, it becomes unresponsive. The probability of this problem occurring is 90%. I read https://react-unity-webgl.dev/docs/api/unload (Unloading the Unity Application) The original text reads: "Since React Unity WebGL version 10, calling the unload function is no longer necessary to unmount the Unity Application. The Unity Application will automatically be unmounted when the component is removed from the DOM. However, if you want to unload the Unity Application manually, you can still use the unload function. But be aware that this is not necessary in most cases." I tried including the unload code and not including it, but it still caused the browser to become unresponsive. I have tested the code according to the API, and the unresponsive situation still occurred.
Reproducible test case
No response
Would you be interested in contributing a fix?