nandorojo / moti

🐼 The React Native (+ Web) animation library, powered by Reanimated 3.
https://moti.fyi
MIT License
3.9k stars 120 forks source link

MotiView mount animation is not fired in some circunstances #332

Closed hlarrainq closed 5 months ago

hlarrainq commented 5 months ago

Is there an existing issue for this?

Do you want this issue prioritized?

Current Behavior

MotiView mount animation is not fired in some circunstances (Android Emulator, iOS playing pip videos, and another random moments on both platforms). I have the suspect that is caused by a incompatibility from NativeBaseProvider.

Expected Behavior

MotiView mount animation should start at any circunstance.

Steps To Reproduce

  1. Create a Expo + RN project.
  2. Create a MotiView with a mount animation using from and animate props.
  3. Use NativeBase and wrap the view with NativeBaseProvider
  4. Open Expo Go on Android Emulator and start to use the app
  5. Eventually, all animations will stop the mount transitions. (This is not fully reproducible, because sometimes works and sometime fails, i can't find the bug)

Versions

- Moti: 0.25.4
- Reanimated: ~3.3.0
- React Native: 0.72.4

Screenshots

No response

Reproduction

https://github.com/hlarrainq/moti-bug-on-mount.git

hlarrainq commented 5 months ago

I removed NativeBaseProvider wrapper from my app, but i still get the random stuck mount animation on Android :( Don't know how to reproduce this well, but it is affecting my users. Any info is helpful!

nandorojo commented 5 months ago

Is your code sample reproducing it?

hlarrainq commented 5 months ago

Hey Fernando,

I encountered the issue. The problem is related to reanimated 3.3.0

https://github.com/software-mansion/react-native-reanimated/issues/4434

I was using Expo Go with the latest version of reanimated for it, but i was able to fix it updating and creating a development build.

Thanks for your library!

fuelkoy commented 5 months ago

@hlarrainq Thank you for the information. You pointed me to the right solution also. ❤️

(Btw you could probably close this issue as it is not caused by Moti 😊)

hlarrainq commented 5 months ago

Nice to hear that @fuelkoy :) Closing this issue