This warning is for the BabylonJS and ReactJs tutorial in the documentation, not for react-babylonjs.
This integration of babylon.js into a react application works fine, however there is a nagging warning:
React Hook useEffect has missing dependencies: ‘adaptToDeviceRatio’, ‘antialias’, ‘engineOptions’, ‘onRender’, ‘props’, and ‘sceneOptions’. Either include them or remove the dependency array. However, ‘props’ will change when any prop changes, so the preferred fix is to destructure the ‘props’ object outside of the useEffect call and refer to those specific props inside useEffect
I’m not sure if the dependencies should be added to the dependencies array, because the SceneComponent may not meant to be updated if these dependencies change.
Is there a quick fix for this warning?