apache / apache/cordova-plugin-file
Cannot use plugin due to lack of documentation
- Dominant language
- JavaScript
- Stars
- 744
- Forks
- 754
- Avg merge
- 3d 4h
- Merged PRs (30d)
- 1
Description
Hello,
I have a lot of trouble understanding the documentation of this plugin.
At the beginning you say that I get the global object `cordova.file` when device is ready.
Then under "Where to store files" you explain the properties of the `cordova.file` locations.
And then you explain which exact paths these `cordova.file` locations map to, depending on the platform. Until here everything made perfect sense.
I was expecting something like "write to cordova.file.yourfavouritelocation" later in the documentation. Instead you show an example of how to write a persistent file without reference to the above ... ?
You're using requestFileSystem and LocalFileSystem and somehow my file appears in `data/data//files/files`. **Which cordova.file.location was used here?**
In addition, according to your table under "Android file system layout", files/files should not exist - only "files" and "files/Documents". Maybe a new Android 10 location? I'm targeting API level 29.
The next difficulties come at the section about how to read a file. You say that I need a FileEntry object. Search the documentation with ctrl + f for the word "FileEntry". I see no documentation, **I don't know what that is and how I get it**. Intuitively I would expect something like `var fe = FileEntry(cordova.file.myfavouritelocation, "myfilename.txt")` but I am completely lost here.
Best regards,
Robert
Contributor guide
Research direction
Start with the “Where to store files,” “Android file system layout,” and file-reading sections described in the issue, then trace the documented requestFileSystem and FileEntry usage. Done means the documentation clearly connects cordova.file locations to the write example, explains the Android paths, and defines how to obtain a FileEntry.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, javascript
- Domain
- documentation, mobile-dev
- Issue type
- Documentation
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100