Last active
March 4, 2019 23:53
-
-
Save PabloRegen/dac42dacd73a030aa84d97f475a9cdfd to your computer and use it in GitHub Desktop.
Create a slider input
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const Slider = ({ speed, onSpeedChange }) => { | |
const handleChange = e => onSpeedChange(e.target.value); | |
return ( | |
<input | |
type='range' | |
min='50' | |
max='1000' | |
step='50' | |
value={speed} | |
onChange={handleChange} | |
/> | |
); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment