Skip to content

Commit da8bdd1

Browse files
btnwtndotansimha
andauthoredSep 28, 2020
Allow passing partial hooks when generating programatically. (#4764)
* Update types.ts * added changeset Co-authored-by: Dotan Simha <dotansimha@gmail.com>
1 parent 78b3277 commit da8bdd1

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed
 

‎.changeset/wet-trainers-reply.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@graphql-codegen/plugin-helpers': patch
3+
---
4+
5+
Allow hooks to be defined as partial object

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ export namespace Types {
295295
*
296296
* For more details: https://graphql-code-generator.com/docs/getting-started/lifecycle-hooks
297297
*/
298-
hooks?: LifecycleHooksDefinition;
298+
hooks?: Partial<LifecycleHooksDefinition>;
299299
}
300300

301301
/* Output Builder Preset */

0 commit comments

Comments
 (0)
Please sign in to comment.