graphql-tools-type-uuid

UUID scalar type for graphql-tools

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
graphql-tools-type-uuid
0102.0.14 years ago5 years agoMinified + gzip package size for graphql-tools-type-uuid in KB

Readme

graphql-tools-type-uuid
Build Status Coverage Status
UUID scalar type for graphql-tools

Usage

import { makeExecutableSchema } from 'graphql-tools'
import UUID from 'graphql-tools-type-uuid'

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

export default schema

Minimum amount of module files

$ tree ./node_modules/graphql-tools-type-uuid
./node_modules/graphql-tools-type-uuid
├── README.md
├── dist
│   └── index.js
└── package.json

1 directory, 3 files