We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello, thanks for the nice package. how to add custom emoji? it might be helpful add an example to the document.
i tried like below. is this the right way?
import { useReward } from 'react-rewards'; ... const { reward: confettiReward, isAnimating } = useReward( "rewardId", "emoji", { emoji: ["⚡️", "💥", "✨", "💫", "🌸", "🌟"], } ); ... <button disabled={isConfettiAnimating} onClick={() => { confettiReward(); }} > <span id="confettiReward" /> 🎉 </button>
The text was updated successfully, but these errors were encountered:
Here is an example that works for me 💜:
import { useReward } from "react-rewards"; . . . const { reward: confettiReward, isAnimating } = useReward( "rewardId", "emoji", { emoji: ["⚡️", "✨", "💜", "🚀"], } ); . . . <button disabled={isAnimating} onClick={() => { confettiReward(); }} > <span id="rewardId" /> 💜 </button>
Sorry, something went wrong.
thank you Ana, We can also use some settings in the readme file
example
const { reward: confettiReward, isAnimating } = useReward("rewardId", "emoji", { emoji: ["⚡️", "💥", "✨", "💫", "🌸", "🌟", "🌂"], elementSize: 15, elementCount: 60, lifetime: 100, });
very nice package 😊
No branches or pull requests
Hello,
thanks for the nice package.
how to add custom emoji? it might be helpful add an example to the document.
i tried like below. is this the right way?
The text was updated successfully, but these errors were encountered: