Minor Changes
- Add
isOfflineError
option to theofflineExchange
to allow it to be customized to different conditions to determine whether an operation has failed because of a network error
Submitted by @robertherber (See #3020) - Allow
updates
config to react to arbitrary type updates other than justMutation
andSubscription
fields.
You’ll now be able to write updaters that react to any entity field being written to the cache,
which allows for more granular invalidations. Note: If you’ve previously usedupdates.Mutation
andupdated.Subscription
with a custom schema with custom root names, you‘ll get a warning since
you’ll have to update yourupdates
config to reflect this. This was a prior implementation
mistake!
Submitted by @kitten (See #2979)
Patch Changes
- ⚠️ Fix regression which caused partial results, whose refetches were blocked by the looping protection, to not have a
stale: true
flag added to them. This is a regression from #2831 and only applies tocacheExchange
s that had theschema
option set
Submitted by @kitten (See #2999) - Add
invariant
to data layer that prevents cache writes during cache query operations. This preventscache.writeFragment
,cache.updateQuery
, andcache.link
from being called inresolvers
for instance
Submitted by @kitten (See #2978) - Updated dependencies (See #3007, #2962, #3007, #3015, and #3022)
- @urql/core@3.2.0