Type '{ updates?: GraphCacheUpdaters | undefined; keys?: GraphCacheKeysConfig | undefined; optimistic?: GraphCacheOptimisticUpdaters | undefined; resolvers?: GraphCacheResolvers | undefined; schema: IntrospectionQuery; }' does not satisfy the constraint 'Partial<CacheExchangeOpts>'.
Types of property 'updates' are incompatible.
Type 'GraphCacheUpdaters | undefined' is not assignable to type 'UpdatesConfig | undefined'.
Type 'GraphCacheUpdaters' is not assignable to type 'UpdatesConfig'.
Property 'Admin' is incompatible with index signature.
Type '{ createdAt?: UpdateResolver<Maybe<WithTypename<Admin>>, Record<string, never>> | undefined; email?: UpdateResolver<Maybe<WithTypename<Admin>>, Record<...>> | undefined; ... 6 more ...; verifiedAt?: UpdateResolver<...> | undefined; }' is not assignable to type 'void | { [fieldName: string]: void | ((parent: DataFields, args: Variables, cache: Cache, info: ResolveInfo) => void); }'.
Type '{ createdAt?: UpdateResolver<Maybe<WithTypename<Admin>>, Record<string, never>> | undefined; email?: UpdateResolver<Maybe<WithTypename<Admin>>, Record<...>> | undefined; ... 6 more ...; verifiedAt?: UpdateResolver<...> | undefined; }' is not assignable to type '{ [fieldName: string]: void | ((parent: DataFields, args: Variables, cache: Cache, info: ResolveInfo) => void); }'.
Property 'createdAt' is incompatible with index signature.
Type 'UpdateResolver<Maybe<WithTypename<Admin>>, Record<string, never>>' is not assignable to type 'void | ((parent: DataFields, args: Variables, cache: Cache, info: ResolveInfo) => void)'.
Type 'UpdateResolver<Maybe<WithTypename<Admin>>, Record<string, never>>' is not assignable to type '(parent: DataFields, args: Variables, cache: Cache, info: ResolveInfo) => void'.
Types of parameters 'parent' and 'parent' are incompatible.
Type 'DataFields' is not assignable to type 'Maybe<WithTypename<Admin>>'.
Property '__typename' is missing in type 'DataFields' but required in type '{ __typename: "Admin"; }'.
Which packages are impacted by your issue?
No response
Describe the bug
When using
@graphql-codegen/typescript-urql-graphcache
at version^3.1.0
the resulting types aren't compatible withurql
'scacheExchange
types.It seems to work with an older version of
@graphql-codegen/typescript-urql-graphcache
though, like^2.4.0
Your Example Website or App
Sorry, can't really provide one
Steps to Reproduce the Bug or Issue
Generated admin type:
Generated
GraphCacheUpdaters
:urql cacheExchange:
Error message:
Expected behavior
No type errors
Screenshots or Videos
No response
Platform
graphql
version: ^16.8.1@graphql-codegen/*
version(s):Codegen Config File
Additional context
No response