APIExtensionDefinition

APIExtensionDefinition

Documentation generated from vendure-plugin.ts on Mar 14 2019 at 20:14

An object which allows a plugin to extend the Vendure GraphQL API.

Signature

interface APIExtensionDefinition {
  schema: DocumentNode;
  resolvers: Array<Type<any>>;
}

Members

schema

property
type:
DocumentNode

The schema extensions.

Example

const schema = gql`extend type SearchReindexResponse {
timeTaken: Int!
indexedItemCount: Int!
}`;

resolvers

property
type:
Array<Type<any>>

An array of resolvers for the schema extensions. Should be defined as Nest GraphQL resolver classes, i.e. using the Nest @Resolver() decorator etc.

alpha