Skip to content
This repository was archived by the owner on Nov 27, 2024. It is now read-only.

Commit bf3bc05

Browse files
authored
add install requirements to readme
1 parent 16c55e0 commit bf3bc05

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

README.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,17 @@ The example at the bottom of this readme demonstrates the intuitive API, but sho
1111
- can be used as a spy to observe real network requests
1212
- isomorphic, and supports either a global fetch instance or a locally required instanceg
1313

14+
# Requirements
15+
fetch-mock-jest requires the following to run:
16+
17+
- [Node.js](https://Node.js.org/) 8+ for full feature operation
18+
- [Node.js](https://Node.js.org/) 0.12+ with [limitations](http://www.wheresrhys.co.uk/fetch-mock/installation)
19+
- [npm](https://www.npmjs.com/package/npm) (normally comes with Node.js)
20+
- [jest](https://www.npmjs.com/package/jest) 25+ (may work with earlier versions, but untested)
21+
- Either
22+
- [node-fetch](https://www.npmjs.com/package/node-fetch) when testing in Node.js. To allow users a choice over which version to use, `node-fetch` is not included as a dependency of `fetch-mock`.
23+
- A browser that supports the `fetch` API either natively or via a [polyfill/ponyfill](https://ponyfoo.com/articles/polyfills-or-ponyfills)
24+
1425
# Installation
1526

1627
`npm install -D fetch-mock-jest`
@@ -30,7 +41,7 @@ const fetchMock = require('node-fetch')
3041

3142
## Setting up mocks
3243

33-
Please refer to the [fetch-mock documentation](http://wheresrhys.co.uk/fetch-mock)
44+
Please refer to the [fetch-mock documentation](http://wheresrhys.co.uk/fetch-mock) and [cheatsheet](https://github.com/wheresrhys/fetch-mock/blob/master/docs/cheatsheet.md)
3445

3546
All jest methods for configuring mock functions are disabled as fetch-mock's own methods should always be used
3647

0 commit comments

Comments
 (0)