itinance / itinance/react-native-fs
flow errors
- Dominant language
- C++
- Stars
- 5k
- Forks
- 1k
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
I cloned the `master` branch [https://github.com/itinance/react-native-fs.git](url) then I install the packages, but when I try to run `yarn flow` , i had a bunch of errors.
```
FS.common.js:10:27
Cannot resolve module react-native.
7│
8│ // This file supports both iOS and Android
9│
10│ var RNFSManager = require('react-native').NativeModules.RNFSManager;
11│
12│ var NativeEventEmitter = require('react-native').NativeEventEmitter;
13│
FS.common.js:12:34
Cannot resolve module react-native.
9│
10│ var RNFSManager = require('react-native').NativeModules.RNFSManager;
11│
12│ var NativeEventEmitter = require('react-native').NativeEventEmitter;
13│
14│ var RNFS_NativeEventEmitter = new NativeEventEmitter(RNFSManager);
15│
FS.common.js:18:21
Cannot resolve module react-native.
15│
16│ var base64 = require('base-64');
17│ var utf8 = require('utf8');
18│ var isIOS = require('react-native').Platform.OS === 'ios';
19│
20│ var RNFSFileTypeRegular = RNFSManager.RNFSFileTypeRegular;
21│ var RNFSFileTypeDirectory = RNFSManager.RNFSFileTypeDirectory;
FS.common.js:504:42
Cannot call options.begin because undefined [1] is not a function.
[1] 75│ begin?: (res: DownloadBeginCallbackResult) => void;
501│
502│ if (options.begin) {
503│ subscriptions.push(RNFS_NativeEventEmitter.addListener('DownloadBegin', (res) => {
504│ if (res.jobId === jobId) options.begin(res);
505│ }));
506│ }
507│
FS.common.js:510:42
Cannot call options.progress because undefined [1] is not a function.
[1] 76│ progress?: (res: DownloadProgressCallbackResult) => void;
507│
508│ if (options.progress) {
509│ subscriptions.push(RNFS_NativeEventEmitter.addListener('DownloadProgress', (res) => {
510│ if (res.jobId === jobId) options.progress(res);
511│ }));
512│ }
513│
FS.common.js:516:34
Cannot call options.resumable because:
• undefined [1] is not a function.
• no arguments are expected by function type [1].
[1] 77│ resumable?: () => void; // only supported on iOS yet
513│
514│ if (options.resumable) {
515│ subscriptions.push(RNFS_NativeEventEmitter.addListener('DownloadResumable', (res) => {
516│ if (res.jobId === jobId) options.resumable(res);
517│ }));
518│ }
519│
Found 7 errors
Done in 1.42s.
```
The problem is that I want to use `react-native-fs` in my project I when Im trying to commit my changes, the pipeline fails in my private project but then when i tried to look for the errors i found this. So i tried to run `flow` in `react-native-fs` project only, and theses are the same errors.
@itinance : any help would be greatly appreciated.
Thank you
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.