You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[expo-image]: Accessing event payload through "nativeEvent" is deprecated, it is now part of the event object itself
Here is the diff that solved my problem:
diff --git a/node_modules/react-native-image-progress/index.js b/node_modules/react-native-image-progress/index.js
index 6b60823..ee6ac8a 100644
--- a/node_modules/react-native-image-progress/index.js+++ b/node_modules/react-native-image-progress/index.js@@ -125,7 +125,7 @@ export const createImageProgress = (ImageComponent) =>
};
handleProgress = (event) => {
- const progress = event.nativeEvent.loaded / event.nativeEvent.total;+ const progress = event.loaded / event.total;
// RN is a bit buggy with these events, sometimes a loaded event and then a few
// 100% progress – sometimes in an infinite loop. So we just assume 100% progress
// actually means the image is no longer loading
@@ -141,7 +141,7 @@ export const createImageProgress = (ImageComponent) =>
handleError = (event) => {
this.setState({
loading: false,
- error: event.nativeEvent,+ error: event,
});
this.bubbleEvent('onError', event);
};
The text was updated successfully, but these errors were encountered:
Today I used patch-package to patch
[email protected]
for the project I'm working on.After migrating from react-native-fast-image to expo-image, this warning indicator started to appear in my CLI:
Here is the diff that solved my problem:
The text was updated successfully, but these errors were encountered: