We have a use case where our app wants to download a text file from the cloud - got this working - but then write the text file downloaded from the cloud to a USB flash drive plugged into the phone device.
I saw this for iOS - Connect external storage devices to iPhone - Apple Support)%2C%20FAT32%2C%20or%20FAT.
“You can use the Files app and other supported apps to access files stored on external devices, such as USB drives and SD cards, connected to your iPhone.”
What constitutes a supported app?
Are there plugins that support this for both Android and iOS?
Thanks for any information.
A little more information. So far, I’ve tried the following plugins:
@capawesome/capacitor-file-picker
@capacitor/filesystem
@capacitor/share
Using FilePicker
, I can successfully pick a file from the device’s internal storage. However, when I select the USB drive as the destination, the plugin returns a content://
URI (I believe Android uses the Storage Access Framework (SAF) for external drives).
From what I’ve gathered, none of these plugins support writing to content://
URIs, which means I can’t actually copy a file to the USB drive using these APIs.
Questions:
-
Is my understanding correct — that Capacitor plugins do not currently support writing to content://
destinations like USB drives via SAF?
-
Are there any workarounds?
-
Any plans for Capacitor or community plugins to support this in the future?
Thanks!