-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
File Plugin: How to obtain a DirectoryEntry/FileEntry of existing Directories/Files #657
Comments
I have the same requirement. I'd like to check if a file already exists and return the FileEntry without modifying it. |
Just pushed a commit (not merged yet) that makes resolveLocalFilesystemUrl and resolveDirectoryUrl methods public instead of private. They return a promise that resolves with Entry and DirectoryEntry respectively. |
And I just made getFile and getDirectory public as well. |
You will still have to do something like that. Ionic Native exports a wrapper for that function as well. You will need to do something like:
|
Thank you very much, this will help a lot! |
Is there a way to update https://github.com/driftyco/ionic-native-bower with the |
Hi,
is there an undocumented way to obtain a 'DirectoryEntry'/'FileEntry' of existing directories/files?
When creating Dirs/Files via
createDir
orcreateFile
the promise returns a handy Entry type, but how to get it for already existing entries? Do I really have to use the low-levelwindow.resolveLocalFilesystemUrl
?getDirectory
orgetFile
are present but _private
_.I think it is a good idea to provide such methods for the completeness of the API. Use-Case: check if a directory is present, if not create it and return a
DirectoryEntry
otherwise return theDirectoryEntry
.The text was updated successfully, but these errors were encountered: