Skip to content

A graphql-code-generator plugin that generates type policies for `enum detail` types within your schema

Notifications You must be signed in to change notification settings

homebound-team/graphql-typescript-enum-type-policies

Repository files navigation

NPM

This is a graphql-code-generator plugin that generates type policies for enum detail types within your schema.

Overview

The Apollo InMemory Cache needs to know that for enum detail types, the code field is the keyField, instead of the typical id field, which does not exist on enum detail types.

Contributing

In order to develop changes for this package, follow these steps:

  1. Make your desired changes in the src directory

  2. Adjust the example files under the integration directory to use your new feature.

  3. Run yarn build, to create a build with your changes

  4. Run yarn graphql-codegen, and verify the output in graphql-types.ts matches your expected output.

About

A graphql-code-generator plugin that generates type policies for `enum detail` types within your schema

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •