You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 15, 2022. It is now read-only.
Spent hours digging into issue with Slider not working properly and throwing the error
TypeError: Cannot read property 'getBoundingClientRect' of null
It would lose its sliderRef.current. In the end it turns out it was unrelated to the slider component, and instead related to me not assigning a persistent key value to the DatGui component itself. Out of habit I was using a counter to assign unique keys to components, and seemingly unless key is persistent between renders DatGui does not work as expected.
This is perhaps obvious, but it wasn't to me. If you run into this issue, here's saving you a few hours.
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Spent hours digging into issue with Slider not working properly and throwing the error
TypeError: Cannot read property 'getBoundingClientRect' of null
It would lose its sliderRef.current. In the end it turns out it was unrelated to the slider component, and instead related to me not assigning a persistent key value to the DatGui component itself. Out of habit I was using a counter to assign unique keys to components, and seemingly unless key is persistent between renders DatGui does not work as expected.
This is perhaps obvious, but it wasn't to me. If you run into this issue, here's saving you a few hours.
The text was updated successfully, but these errors were encountered: