Skip to content

Commit bb1e0e9

Browse files
authored
Add noSilentErrors option to the config type (#9523)
* update CodegenConfig type (add property) * update config.schema.json by building website run `yarn build` in website * add a changeset
1 parent a737ede commit bb1e0e9

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed

.changeset/large-wombats-beam.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@graphql-codegen/plugin-helpers': patch
3+
---
4+
5+
add noSilentErrors option to the config type

packages/utils/plugins-helpers/src/types.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -543,6 +543,10 @@ export namespace Types {
543543
* For more details: https://graphql-code-generator.com/docs/config-reference/lifecycle-hooks
544544
*/
545545
hooks?: Partial<LifecycleHooksDefinition>;
546+
/**
547+
* @description Alows to raise errors if any matched files are not valid GraphQL. Default: false.
548+
*/
549+
noSilentErrors?: boolean;
546550
}
547551

548552
export type ComplexPluginOutput = { content: string; prepend?: string[]; append?: string[] };

website/public/config.schema.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,10 @@
9696
"hooks": {
9797
"$ref": "#/definitions/Partial",
9898
"description": "Specifies scripts to run when events are happening in the codegen core.\nHooks defined on that level will effect all output files.\n\nFor more details: https://graphql-code-generator.com/docs/config-reference/lifecycle-hooks"
99+
},
100+
"noSilentErrors": {
101+
"description": "Alows to raise errors if any matched files are not valid GraphQL. Default: false.",
102+
"type": "boolean"
99103
}
100104
}
101105
},

0 commit comments

Comments
 (0)