2.0.2 • Published 5 years ago

graphql-tools-type-uint v2.0.2

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

graphql-tools-type-uint

Build Status Coverage Status

UInt (unsigned int) scalar type for graphql-tools

Usage

import { makeExecutableSchema } from 'graphql-tools'
import UInt from 'graphql-tools-type-uint'

let typeDefs = [`
scalar UInt
type Query {
  value(v: UInt): UInt
}`
]
let resolvers = {
  UInt,
  Query: {
    value: (root, { v }) => v
  }
}
let schema = makeExecutableSchema({ typeDefs, resolvers })

export default schema