Open tristanheilman opened 10 months ago
Did you find a fix?
I figured it out its using old deprecated methods from react-native-reanimated so i updated those and it now works.
Heres my PR: https://github.com/browniefed/react-native-ticker/pull/43
Hey @arichayo, I was also facing this same issue so I upgraded to the latest version that you guys pushed but the UI looks weird. Please check attached screenshot.
Hit an issue today after upgrading react-native-reanimated from 2.15.1 -> 3.5.4
Redbox error while developing on iOS & Android showed an issue in this packages index.js file for
cannot read property 'prototype' of undefined react native ticker
The issue pointed to the widthAnim value/function line.I dug into this a bit and made some changes to the files to utilize better logic for running the animations and ultimately fixed the issue I was experiencing. I also solved a problem with the string length changing and preventing the last character(s) from animating.
Ex. Initial value rendered is $0.00 but changes after API fetches data to $52.50. The component would only animate the first three characters in the new string, leaving the 0 stale.
Ex. Initial value rendered is $0.00 but changes after API fetches data to $134.42. The component would only animate the first three characters in the new string, leaving the final 42 characters stale with no animation.
My changes fixes the Redbox bug as well as improves on the current animations running when the string value changes.
I created a patch file that includes all of this if anybody else experiences the issue.