CrazyTim / spin-wheel

An easy to use, themeable component for randomising choices and prizes.
https://crazytim.github.io/spin-wheel/examples/themes
MIT License
203 stars 53 forks source link

Pass the output from the external API? #29

Closed tv-ankur closed 6 months ago

tv-ankur commented 8 months ago

Is it possible to pass the output from the external API?

I have external API that return the result of wheel that I want to pass as the output into wheel. Is it possible?

CrazyTim commented 8 months ago

Hi @tv-ankur see the README for examples how to spin the wheel.

Is there something specific that you're not sure about? Feel free to post a code example of what you are trying to do so others can help.

367null commented 5 months ago

yes its possible u need to parse the response using JSON.parse if its a JSON format and get the value after that validate it and use wheel.spinToItem(value)