JSPM

  • Created
  • Published
  • Downloads 45570
  • Score
    100M100P100Q160674F
  • License SEE LICENSE IN LICENSE

GraphQL IDE for better development workflows (GraphQL Subscriptions, interactive docs & collaboration).

Package Exports

  • graphql-playground-middleware-koa

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (graphql-playground-middleware-koa) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

graphql-playground-middleware-koa

Koa middleware to expose an endpoint for the GraphQL Playground IDE

Installation

Using yarn:

yarn add graphql-playground-middleware-koa

Or npm:

npm install graphql-playground-middleware-koa --save

Usage

See full example in examples/basic.

const koa = require('koa')
const koaRouter = require('koa-router')
const koaPlayground = require('graphql-playground-middleware-koa')

const app = new koa()
const router = new koaRouter()

router.all('/playground', koaPlayground({ endpoint: '/graphql' }))