rive-app / rive-app/rive-react-native
onLoopEnd is not called in iOS but is called on android
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 783
- Forks
- 81
- Avg merge
- 3d 6h
- Merged PRs (30d)
- 3
Description
Description
For the same .riv file, onLoopEnd is called properly on android it is not called on iOS.
Use case is to store when that animation is shown to the user after animation is played and not animate again
Provide a Repro
<Rive
ref={animationRef}
style={{ width: 48, height: 48 }}
resourceName={'offers_tab'}
onLoopEnd={onAnimationEnd}
/>
Source .riv/.rev file
Expected behaviour
Trigger onLoopEnd callback similar to android
Device & Versions (please complete the following information)
- Device: iPhone 11
- OS: 17.4.1
- NPM Version: 10.2.4
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the provided repro and compare the iOS and Android paths for the onLoopEnd callback, using the attached Offers tab asset to reproduce the mismatch on an iPhone 11 running iOS 17.4.1. Done means the callback fires on iOS as it already does on Android for the same animation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react-native, typescript
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100