itinance / itinance/react-native-fs
Content URI directory support
- Dominant language
- C++
- Stars
- 5k
- Forks
- 1k
- PR merge metrics
- No merged PRs in 30d
Description
When I pick a single file, it works fine:
```javascript
const res = await DocumentPicker.pick();
const content = await fs.readFile(res[0].uri);
// good
```
When I pick a directory, it does not work:
```javascript
const res = await DocumentPicker.pickDirectory();
const dirs = await fs.readDir(decodeURIComponent(res.uri)); // decode the uri or it will throw a unsupported error
// not worked, throw a error: Permission Denial...ACTION_OPEN_DOCUMENT...
```
I see the same problem in this [PR](https://github.com/itinance/react-native-fs/pull/395#issuecomment-355013695), but I don't konw how to do.
Environments:
```
Android 8.0
react-native@0.66.0
react-native-fs@2.18.0
react-native-document-picker@7.1.1
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.