Right now we have the following properties as function params:
enabled: Boolean = true,
startDelay: Duration = Duration.ZERO,
duration: Duration = 10L.seconds,
restDuration: Duration = duration,
Maybe it make sense to extract a state object like ProgressButtonState that contains those values as State<Boolean|Duration>.. 🤔
We should also introduce a rememberProgressButtonState() that returns that (remembered) state.
Users of the ProgressButton can simply put the state into the ProgressButton itself and update the state instead of calling the ProgressButton function again.
Does this make sense? 🤔
Right now we have the following properties as function params:
Maybe it make sense to extract a state object like
ProgressButtonStatethat contains those values asState<Boolean|Duration>.. 🤔We should also introduce a
rememberProgressButtonState()that returns that (remembered) state.Users of the ProgressButton can simply put the state into the
ProgressButtonitself and update the state instead of calling the ProgressButton function again.Does this make sense? 🤔