gre / multi-slider

React component for multiple values slider (allocate values)
http://gre.github.io/multi-slider
49 stars 31 forks source link

replace string ref with callback function #12

Closed andyweiss1982 closed 6 years ago

andyweiss1982 commented 6 years ago

I encountered this error using this package: https://reactjs.org/warnings/refs-must-have-owner.html

And discovered that string refs are considered legacy: https://reactjs.org/docs/refs-and-the-dom.html#legacy-api-string-refs

And applied the suggested fix: https://reactjs.org/docs/refs-and-the-dom.html#adding-a-ref-to-a-dom-element.

And now I no longer encounter the error.