@@ -39,23 +39,15 @@ First, install DataLoader using npm.
3939npm install --save dataloader
4040```
4141
42- DataLoader assumes a JavaScript environment with global ES6 ` Promise ` and ` Map `
43- classes, available in the recent versions of node.js or when using
44- [ babel/polyfill] [ ] . If your environment does not have these, provide them before
45- using DataLoader.
46-
47- ``` js
48- global .Promise = require (' es6-promise' )
49- global .Map = require (' es6-map' )
50- ```
51-
5242To get started, create a ` DataLoader ` . Each ` DataLoader ` instance represents a
53- unique cache. You might create each loader once for your whole application, or
54- create new instances per request when used within a web-server like [ express] [ ]
55- if different users can see different things. It's up to you.
43+ unique cache. Typically instances are created per request when used within a
44+ web-server like [ express] [ ] if different users can see different things.
45+
46+ > Note: DataLoader assumes a JavaScript environment with global ES6 ` Promise `
47+ and ` Map ` classes, available in all supported versions of Node.js.
5648
5749
58- ### Batching
50+ ## Batching
5951
6052Batching is not an advanced feature, it's DataLoader's primary feature.
6153Create loaders by providing a batch loading function.
@@ -130,7 +122,7 @@ with the original keys `[ 2, 9, 6, 1 ]`:
130122```
131123
132124
133- ### Caching
125+ ## Caching
134126
135127DataLoader provides a cache for all loads which occur in a single request to
136128your application. After ` .load() ` is called once with a given key, the resulting
0 commit comments