Selection causes endless loop
Using selection API causes the child components stuck in endless loop
<Selection> <Select enabled> <mesh position={[5, 5, 0]}> <boxGeometry /> <meshStandardMaterial color="orange" /> </mesh> </Select> </Selection>
Any updates on this? I'm using the latest rc (3.0.0-rc.2) As long as Select enabled is true it causes endless updates.
I'm not an expert in React or this library, but the bug seems to be in this code. api.select calls a setState which causes the component to re-render calling the cleanup for the effect, which remove the object from the selection, and it's added back in when the effect reruns, etc.
I am using 3.0.4 and it is still causing an endless update loop in react.