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

fix: line chart wont interpolate on data changes #149

Merged
merged 4 commits into from
Dec 22, 2023

Conversation

Amurmurmur
Copy link
Contributor

After upgrading to Expo v49 and react-native-reanimated v3 the chart will not interpolate on data switch due to previous value always being returned as null.

The same code works fine with Reanimated v2 and expo v48, most likely a buggy on the reanimated side (issue raised with them no feedback yet)

As of now this PR fixes it to support Reanimated v3 and Expo v49.

fix: useAnimatedReaction previous value being null
@Amurmurmur
Copy link
Contributor Author

@arancauchi

Copy link
Contributor

@cam-shaw cam-shaw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As this PR is for a line interpolation fix, it would be good to isolate the changes to just what's needed to fix the bug.
Great to see the contribution as it's a good one for the project! 🙌

example/package.json Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
example/package.json Show resolved Hide resolved
@Amurmurmur Amurmurmur requested a review from cam-shaw July 27, 2023 16:36
@LeoAnt02
Copy link

LeoAnt02 commented Jul 29, 2023

Hey @Amurmurmur ,
Thanks so much for this PR

Just curious, how is this tested on web ?
Expo SDK49 introduce the metro web bundler that will slowly replace webpack

I think we should ensure that we support both

edit : I've tested the current version v2.3.0 on metro on web, expo 49, and reanimated v3.4.0 and the linear chart is working clean, no flicker, no issues

@arancauchi arancauchi merged commit 0489133 into coinjar:master Dec 22, 2023
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

Successfully merging this pull request may close these issues.

4 participants