We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1b9c99e commit a0b334bCopy full SHA for a0b334b
README.md
@@ -8,14 +8,14 @@ No fetch mock could be used easily for react-native.
8
So, I create one by myself.
9
10
## Roadmap
11
-- [ ] Combined with Mock.js
+- [x] Combined with Mock.js
12
13
## Usage
14
```
15
import FetchMock from 'react-native-fetch-mock';
16
17
if (__dev__) {
18
- global.fetch = FetchMock('path/to/mocks/directory');
+ global.fetch = FetchMock(require('path/to/mocks/directory'));
19
}
20
21
// if __dev__ is true, it will back the data you defined in mock directory
0 commit comments