Feature Request: Different start than end value on animation
Closed this issue · 2 comments
Leo310 commented
Right now you can only provide one value which is displayed at the start and at the end of the animation.
As I want to use it as a slot machine would it be possible to provide a different value at the beginning so that the user won't know what the end result will be?
Something like this:
<SlotCounter
startValue={123456}
endValue={231535}
charClassName="char"
separatorClassName="sep"
/>
almond-bongbong commented
Thank you for your suggestion. This is an interesting idea, and i plan to immediately update our library with this feature.
Thank you!
almond-bongbong commented
This feature was released in version 1.7.0. We've added the startValue prop for setting the initial display value. Here's an example:
<SlotCounter
startValue="???"
value="777"
/>
If this feature doesn't match your use case, please feel free to reach out at any time.