Mirror: Modular GraphQL.js import paths without the hassle.
1# babel-plugin-modular-graphql
2
3A small transform plugin to cherry-pick GraphQL modules so you don’t have to.
4Basicaly [babel-plugin-lodash](https://github.com/lodash/babel-plugin-lodash) for [graphql](https://github.com/graphql/graphql-js).
5
6## Getting Started
7
8```sh
9npm install --save-dev babel-plugin-modular-graphql
10# or
11yarn add --dev babel-plugin-modular-graphql
12```
13
14And add the plugin to your Babel config; it doesn't take any options.
15
16## Example
17
18Imports like these:
19
20```js
21import { parse, Kind } from 'graphql';
22```
23
24Become:
25
26```js
27import { parse } from "graphql/language/parser";
28import { Kind } from "graphql/language/kinds";
29```