Uploading very large video files can cause the async launchImageLibrary call to take an extraordinary long time (up to 12min for a 3gb file)
I applied the optional params as an attempt to reduce the size of the video file; however, this did not work. I then started running my own tests using the same 30s video with different options being used, and I noticed that the file size never changed.
How to repeat issue and example
Use the launchImageLibrary function to select a video from your gallery and console log the resulting file size:
const result = await launchImageLibrary(options?);
const { fileSize } = result.assets[0];
console.log(fileSize); // All file sizes are the same
FILE SIZE: 57,187,279
FILE SIZE: 57,187,279
FILE SIZE: 57,187,279
Additional Information
Image Picker version: 5.3.1
React Native version: 0.71.7
Platform: iOS
Development Operating System: MacOS, M1 chip
Dev tools: VS Code, Expo-ejected React Native Bare Workflow, iOS Physical Device
Description
Uploading very large video files can cause the async launchImageLibrary call to take an extraordinary long time (up to 12min for a 3gb file)
I applied the optional params as an attempt to reduce the size of the video file; however, this did not work. I then started running my own tests using the same 30s video with different options being used, and I noticed that the file size never changed.
How to repeat issue and example
Use the launchImageLibrary function to select a video from your gallery and console log the resulting file size:
FILE SIZE: 57,187,279
FILE SIZE: 57,187,279
FILE SIZE: 57,187,279
Additional Information