Replies: 1 comment 2 replies
-
Android abstracts the presence of the sdcard. There is a partition that acts as an external storage medium when the sdcard is not present, which is generated represented as I think if there is a physical sdcard present then the path will be There is a lot of devices available that doesn't have any sdcard slot, so it's unwise to rely on the presence sdcards. These devices still emulates external storage however. |
Beta Was this translation helpful? Give feedback.
-
I am using the 'File' plugin in my app, and it downloads some files to the device from a remote web server. I am trying to work out how to check if an sdcard exists in the device.
If I test this on a emulator without an sdcard, I was hoping that the value of cordova.file.externalRootDirectory would be null, which would mean I could use that, but its not null, even without a sdcard in the device, cordova.file.externalRootDirectory has a value of 'file:///storage/emulated/0/'
How best to check for existence of sdcard?
Beta Was this translation helpful? Give feedback.
All reactions