0

React-native-image-picker is in use in Android 13 environment. I'm using launchImageLibrary when I need to select an image for an album, but I'm getting an error that all albums don't show up.

The phenomenon does not occur in versions below Android 12, but it is identified as an error that occurs when it changes to photopicker on the way to Android 13 environment. Is there any way to look up all the folders that contain images? I think there is a way to access my file application by displaying 'more' in the image picker, could you tell me if there is a way?

import { launchImageLibrary, launchCamera } from "react-native-image-picker";

...

    const imagePickerOption = {
        mediaType: "photo",
        // maxWidth: 768,
        // maxHeight: 768,
        includeBase64: Platform.OS === "android",
    };

    const onLaunchImageLibrary = () => { //open album
        // @ts-ignore
        launchImageLibrary(imagePickerOption, onPickImage);
    };

I have received permission requests and added all the necessary permissions.

    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
    <uses-permission android:name="android.permission.READ_MEDIA_IMAGES" />
2
  • what is your react-native-image-picker version
    – Shivo'ham
    Commented Nov 9, 2023 at 5:07
  • I'm using v5.0.0, it works till Android 12, but not in 13
    – Yogendra
    Commented Feb 15, 2024 at 11:37

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.