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

Images from baronha/react-native-multiple-image-picker not displayed in ImageBackground on Android and ios #214

Open
jazzylamba opened this issue Dec 31, 2024 · 0 comments

Comments

@jazzylamba
Copy link

ImageBackground does not display images when provided with content:// URIs. This issue occurs when attempting to use images from Android's media storage.
When using the react-native-multiple-image-picker package to select images, the paths returned (e.g., content:// URIs) do not render correctly in the ImageBackground component on Android.

Attempting to use the returned paths (result.path, result.localUri, result.realPath, result.uri) as the source for ImageBackground results in the image not being displayed.

Steps to Reproduce
Install and configure baronha/react-native-multiple-image-picker in a React Native project.
Select an image from Android's or ios media storage using the package.
Use the returned result.path or other URI properties as the source for an ImageBackground component:

<ImageBackground
  source={{ uri: result?.path || result?.localUri || result?.realPath || result?.uri }}
  resizeMode="contain"
  style={{
    height: 300,
    width: 300,
  }}
/>
@jazzylamba jazzylamba changed the title Images from react-native-multiple-image-picker not displayed in ImageBackground on Android and ios Images from baronha/react-native-multiple-image-picker not displayed in ImageBackground on Android and ios Dec 31, 2024
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