customautosys commented on issue #334: URL: https://github.com/apache/cordova/issues/334#issuecomment-1264525332
> > It really is the way forward for file saving on Android. > > That's not entirely accurate. Scoped Storage (And the MediaStore APIs) are for dealing with files that uses the External storage system on android. a Media Store plugin could be used in addition to the file plugin, but it definitely won't replace the file plugin, which can interact with both the internal filesystem as well as the external filesystem. Currently the file plugin handles this through the [Direct File API](https://developer.android.com/about/versions/11/privacy/storage#media-direct-file-native). But I do understand the MediaStore is the recommended approach for interfacing with the external filesystem. > > To be clear, I'm not pushing back on the MediaStore API. I'm just asking the _what_ it provides over the File plugin or _why_ it's not practical. For example, how were you providing UI to the user to choose where to save a file before and why doesn't that work now? I was using https://github.com/ourcodeworld/cordova-ourcodeworld-filebrowser which does not display the files in the folders disallowed by scoped storage. When you navigate to such a folder then you can't go anywhere and you're stuck and have to close the picker. That's why I had to write the MediaStore / SAF plugin. File plugin also fails on a scoped storage device whenever you write to something that's not the app's own folder, whether in internal or external storage. So it ends up being pretty limited. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
