Options
All
  • Public
  • Public/Protected
  • All
Menu

EF Primitive GraphQL Types

Provides a GraphQL types for representing EF Carbon Primitives.

import { GraphQLObjectType } from 'graphql';

import { Guid } from '@ef-carbon/primitive'
import { GraphQLNonNullGuid } from '@ef-carbon/graphql-type-primitive';

const query = new GraphQLObjectType({
  name: 'Query',
  fields: {
    primitive: {
      type: GraphQLNonNullGuid,
      resolve: () => new Guid('fb123594-3344-466e-815b-d610e42718a9'),
    },
  }
});