diff --git a/.changeset/quiet-panthers-wink.md b/.changeset/quiet-panthers-wink.md new file mode 100644 index 00000000..7a78578f --- /dev/null +++ b/.changeset/quiet-panthers-wink.md @@ -0,0 +1,5 @@ +--- +"gql.tada": patch +--- + +Extend `readFragment` types to allow `| {}` optional fragments to be matched. When a fragment is annotated with a directive making it optional (such as `@include`, `@skip`, or `@defer`) then its typed as optional. `readFragment` previously didn't know how to match these types, but it will now match `T | {}` and infer the type as such.