Expo 52: Warning: Error: Exception in HostFunction: Loss of precision during arithmetic conversion: (long)
On expo 52 when I compress any image I get the error : "Warning: Error: Exception in HostFunction: Loss of precision during arithmetic conversion: (long)"
It happens on Android (I didn't test on IOS tho)
React Native Version
0.76.2
React Native Compressor Version
1.9.0
I have the same error.
I don't even know where does it happen. But yes, it started to happen after I updated the app to v52.
In my case this error was caused by zIndex, I used react-native-ui-lib for View:
<View
style={{
position: "absolute",
top: 0,
left: 0,
right: 0,
bottom: 0,
//zIndex: Math.round(Number.MAX_VALUE),
pointerEvents: "none",
}}
>
It works if I change that to zIndex: Number.MAX_SAFE_INTEGER
In my case it's occurring in iOS, Android working fine. And yeah removing zindex fixed issue.
Hello, I don't understand, what does your <View> has anything to do with the method compress() ?