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

Error decoding image data <NSData 0x6000030192f0; 82644 bytes> #129

Open
peckpeck20 opened this issue May 9, 2019 · 0 comments
Open

Error decoding image data <NSData 0x6000030192f0; 82644 bytes> #129

peckpeck20 opened this issue May 9, 2019 · 0 comments

Comments

@peckpeck20
Copy link

peckpeck20 commented May 9, 2019

Using the image gallery sometimes some images fail to load and I get a blank screen. Its worth noting that this happens on iOS devices.

Looking more into this, I created a custom img component and logged the error and I get this => Error decoding image data <NSData 0x6000030192f0; 82644 bytes>

this is how my component looks at the moment :

private getCustomImageComponent = (imageProps: any) => { const { width, height } = commonConstants.viewport; return ( <Image {...imageProps} onError={({ nativeEvent: { error } }) => { console.log(error); }} style={{ width: width, height: height }} resizeMode="contain" /> ); };

<SafeAreaView style={commonStyles.safeAreaView}> <Gallery style={[styles.gallery]} images={[{ source: this.props.primaryImage }]} imageComponent={this.getCustomImageComponent} /> <ImageGalleryBanner closeModal={this.props.closeModal} /> </SafeAreaView>

Version:
"react-native-image-gallery": "^2.1.5",
"react": "^16.6.3",
"react-native": "^0.58.5",

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

1 participant