How to use code generator with custom AWS AppSync scalars? #5283
-
I am creating my graphql schema for AWS AppSync. They expose some custom scalars as per https://docs.aws.amazon.com/appsync/latest/devguide/scalars.html#appsync-defined-scalars I tried adding these in my schema: ../server/src/schema.graphql
generates:
./typings/api.ts:
plugins:
- typescript
config:
scalars:
AWSDateTime: Date However am still getting following error $ graphql-codegen
✔ Parse configuration
❯ Generate outputs
❯ Generate ./typings/api.ts
✖ Load GraphQL schemas
→ Failed to load schema
Load GraphQL documents
Generate
Found 1 error
✖ ./typings/api.ts
Failed to load schema from ../server/src/schema.graphql:
Unknown type: "AWSDateTime".
Error: Unknown type: "AWSDateTime". Am I missing something here? Also, while on the topic, I can see that there are many places where |
Beta Was this translation helpful? Give feedback.
Answered by
dotansimha
Dec 17, 2020
Replies: 1 comment
Answer selected by
dotansimha
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
#4311