Skip to content
New issue

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

Animation might not run on iOS #89

Closed
YanVictor1027 opened this issue May 9, 2024 · 2 comments
Closed

Animation might not run on iOS #89

YanVictor1027 opened this issue May 9, 2024 · 2 comments

Comments

@YanVictor1027
Copy link

Please Update the following code in SegmentedArc.js
Animated.timing(arcAnimatedValue, { toValue: lastFilledSegment.filled, duration: animationDuration, delay: animationDelay, useNativeDriver: false, easing: Easing.out(Easing.ease) }).start(); const listenerId = arcAnimatedValue.addListener(e => { if (e.value === lastFilledSegment.filled) animationRunning.current = false; });

To

new Animated.timing(arcAnimatedValue, { toValue: lastFilledSegment.filled, duration: animationDuration, delay: animationDelay, useNativeDriver: false, easing: Easing.out(Easing.ease) }).start(({finished}) => {if (finished) animationRunning.current = false});

As comparing two value might fail due to precision issue.
https://reactnative.dev/docs/animated#start

@jkhusanov
Copy link
Collaborator

Hi @YanVictor1027, have you experienced that issue? So far we have not seen it happening on iOS.

@jkhusanov
Copy link
Collaborator

Closing this issue due to inactivity, please create a new one if you experience this problem again. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants