UNPKG

@omnigraph/json-schema

Version:

This package generates GraphQL Schema from JSON Schema and sample JSON request and responses. You can define your root field endpoints like below in your GraphQL Config for example;

20 lines (19 loc) 581 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.GraphQLVoid = exports.GraphQLFile = void 0; const graphql_1 = require("graphql"); exports.GraphQLFile = new graphql_1.GraphQLScalarType({ name: 'File', description: 'The `File` scalar type represents a file upload.', extensions: { codegenScalarType: 'File', }, }); exports.GraphQLVoid = new graphql_1.GraphQLScalarType({ name: 'Void', description: 'Represents empty values', serialize: () => '', extensions: { codegenScalarType: 'void', }, });