Extra nesting of `decrement` and `increment` may be unnecessary
Closed this issue · 4 comments
TimDaub commented
See this line:
I think it should be possible to just do:
<button type="button" onClick="${decrement}" value="-" />
FabiDau commented
if I do it like that than its called in a loop immediately counts down to 0 without a button click
TimDaub commented
ah yes can be., my bad. Ok closing.
TimDaub commented
@FabiDau are you sure you didn't do decrement()
because that'd cause a loop whereas decrement
shouldn't
FabiDau commented
hm not sure cant see a difference between ${decrement}
||| ${() => decrement()}
works both without loop. I changed it now to ${decrement}