Skip to content

Commit

Permalink
Add example to README
Browse files Browse the repository at this point in the history
  • Loading branch information
ksrb committed Apr 27, 2022
1 parent 9ad6842 commit 1440d05
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,19 @@ This is a [graphql-code-generator](https://graphql-code-generator.com/) plugin t

This plugin generates a [`possibleTypes` object](integration/graphql-types.ts) defining possible types which implement interfaces, [needed by Apollo](https://www.apollographql.com/docs/react/data/fragments/#defining-possibletypes-manually)

## Example
```sh
npm i @homebound/graphql-typescript-possible-types
```

**codegen.yml**
```yml
generates:
integration/graphql-types.ts:
plugins:
- node_modules/@homebound/graphql-typescript-possible-types
```
## Contributing
In order to develop changes for this package, follow these steps:
Expand Down

0 comments on commit 1440d05

Please sign in to comment.