fix sub apollo cache merge errors

This commit is contained in:
keyan 2024-02-15 11:32:09 -06:00
parent afe096e516
commit b5bf0c88e3
1 changed files with 6 additions and 1 deletions

View File

@ -34,7 +34,12 @@ function getClient (uri) {
freezeResults: true,
typePolicies: {
Sub: {
keyFields: ['name']
keyFields: ['name'],
fields: {
optional: {
merge: true
}
}
},
User: {
// https://www.apollographql.com/docs/react/caching/cache-field-behavior/#merging-non-normalized-objects