Change8

@apollo/client@4.2.0-alpha.8

📦 apollo-clientView on GitHub →
1 features🐛 1 fixes🔧 1 symbols

Summary

This patch fixes an issue with `refetchOn` merging logic when default and per-query options conflict, and introduces customization for the default event handler in `RefetchEventManager`.

✨ New Features

  • Added the ability to override the default event handler on RefetchEventManager via the `defaultHandler` constructor option or the `setDefaultEventHandler` instance method.

🐛 Bug Fixes

  • Fixed `refetchOn` merging when `defaultOptions.watchQuery.refetchOn` is set to a non-object value (false, true, or a function) and the per-query `refetchOn` is an object. The default value now correctly applies to unspecified events when the per-query object is present.

Affected Symbols