Created
September 5, 2019 11:46
-
-
Save praveenweb/4bb26a4bdfe38c2ed1c570a8ed6413f2 to your computer and use it in GitHub Desktop.
graphql-code-generator-config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = { | |
"schema": [ | |
{ | |
"http://localhost:8080/v1/graphql": { | |
"headers": { | |
// neccessary auth headers to fetch schema | |
} | |
} | |
} | |
], | |
"documents": [ | |
"./src/**/*.tsx", | |
"./src/**/*.ts" | |
], | |
"overwrite": true, | |
"generates": { | |
"./src/generated/graphql.tsx": { | |
"plugins": [ | |
"typescript", | |
"typescript-operations", | |
"typescript-react-apollo" | |
], | |
"config": { | |
"skipTypename": false, | |
"withHooks": true, | |
"withHOC": false, | |
"withComponent": false | |
} | |
}, | |
"./graphql.schema.json": { | |
"plugins": [ | |
"introspection" | |
] | |
} | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment