react-slider
react-slider copied to clipboard
Typescript issue
When i use defaultValue={[0, 10000]} then getting error in typescript. How can i solve it?
The problem is in the DefinitelyTyped package, not this repo. If possible, you can try and declare a generic for ReactSliderProps, e.g.
import { ReactSliderProps } from 'react-slider';
const props: ReactSliderProps<number[]> = {
defaultValue: [0, 100],
}
<ReactSlider defaultValue={props.defaultValue} />