1.0.0-rc.2 • Published 4 months ago

generate-graphql-introspection v1.0.0-rc.2

Weekly downloads
-
License
MIT
Repository
github
Last release
4 months ago

README

npm version

Generate introspection from GraphQL schema.

npm i generate-graphql-introspection --save-dev

Usage:

npx generate-graphql-introspection -s schema.graphql -o introspection.json

Command

Usage:
  # All .graphql files in the graphql directory
  generate-graphql-introspection -s "graphql/*.graphql" -o introspection.json

  # Specify one file
  generate-graphql-introspection -s graphql/schema.graphql -o introspection.json

  # Specify multiple files
  generate-graphql-introspection -s graphql/user.graphql -s graphql/order.graphql -o introspection.json

Options:
  -s --source    Specify the source glob.
  -i --ignore    Specify the rule to ignore files in source.
  -o --output    Specify the output file.
  -h --help      Print help message.

Programmatically usage

import { generateGraphQLIntrospection } from 'generate-graphql-introspection'

generateGraphQLIntrospection({
  source: ['graphql/*.graphql'],
  output: 'introspection.json'
})
1.0.0-rc.2

4 months ago

1.0.0-rc.1

4 months ago

0.0.1-alpha.1

5 months ago