fix behaviour

context-store
Alfred Melch 5 years ago
parent 74c0ed1de0
commit 38b1082772

@ -1,4 +1,4 @@
import React, { useCallback } from 'react'
import React from 'react'
import { useSelector, useDispatch } from 'react-redux'
import { debounce } from 'debounce'
@ -12,15 +12,13 @@ export const Options = () => {
return (
<div>
<h2>Options</h2>
<Slider
title={'Maximum segment length'}
min={3}
max={15}
value={maxLength}
onChange={useCallback(
debounce(val => dispatch(setMaxLength(val)), 100, true),
[dispatch]
)}
onChange={debounce(val => dispatch(setMaxLength(val)), 100)}
/>
<Slider
title={'Words per minute'}

Loading…
Cancel
Save