Skip to content
This repository has been archived by the owner on Jan 31, 2019. It is now read-only.

Latest commit

Β 

History

History
43 lines (36 loc) Β· 1.19 KB

readme.md

File metadata and controls

43 lines (36 loc) Β· 1.19 KB

GraphQL Server

Build Status npm version engine: jokio

High level package built on top of graphql-yoga, to create graphql server with websocket support easily.

Features:

  • All graphql-yoga features
  • Authentication support
  • Apollo Engine support
  • Pre-defined scalar types: Date, Time, DateTime, JSON
  • Pre-defined Graph for getting server stats
  • Remote Schema stitching
  • Local Schema stitching
  • Rest apis integration
  • Dotenv support (for development environment)
  • Web sockets improved support

Example:

import { run } from 'jokio'
import { graphql, LocalSchema } from 'jokio-graphql';

const schema: LocalSchema = {
  typeDefs: `
    extend type Query {
      hello: String
    }
  `,
  resolvers: {
    Query: {
      hello: () => 'world'
    }
  }
}

run(
  graphql({ localSchemas: [schema] })
)