1.0.0 • Published 5 years ago

parse-graphql v1.0.0

Weekly downloads
77
License
MIT
Repository
github
Last release
5 years ago

parse-graphql

NPM version NPM downloads CircleCI donate chat

Given a GraphQL source, parses it into a Document.

Throws GraphQLError if a syntax error is encountered.

This module is basically a standalone version (70KB unminified) for require('graphql').parse (1.8MB).

Install

yarn add parse-graphql

Usage

const { parse } = require('parse-graphql')

parse(`{
  user {
    name
    id
  }
}`)

Contributing

  1. Fork it!
  2. Create your feature branch: git checkout -b my-new-feature
  3. Commit your changes: git commit -am 'Add some feature'
  4. Push to the branch: git push origin my-new-feature
  5. Submit a pull request :D

Author

parse-graphql © EGOIST, Released under the MIT License. Authored and maintained by EGOIST with help from contributors (list).

github.com/egoist · GitHub @EGOIST