Skip to content

Commit e1bef4c

Browse files
committed
improve doc
1 parent 2249678 commit e1bef4c

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,13 @@ yarn add oc-registry-graphql-express-middleware
1111
## How to use it w/in your Registry
1212

1313
```javascript
14-
const middleware = require('oc-registry-graphql-express-middleware');
14+
// todo: get rid of babel-*
15+
require('babel-core/register');
16+
require('babel-polyfill');
1517

16-
registry.app.use('/graphql', middleware({ baseUrl: 'http://localhost:3000/', graphiql: true }));
18+
const graphql = require('oc-registry-graphql-express-middleware');
19+
20+
registry.app.use('/graphql', graphql({ baseUrl: 'http://localhost:3000/', graphiql: true }));
1721
```
1822

1923
![query-registry](query-registry-v2.png "query-registry")

0 commit comments

Comments
 (0)