SIGN IN SIGN UP
TanStack / query UNCLAIMED

🤖 Powerful asynchronous state management, server-state utilities and data fetching for the web. TS/JS, React Query, Solid Query, Svelte Query and Vue Query.

0 0 111 TypeScript

feat(*): add optional logger prop to QueryClient config (#3246)

- remove setLogger
- add optional `logger` prop to QueryClientConfig
- add getLogger public method to QueryClient
- add optional `logger` prop to QueryConfig and MutationConfig
- add getDefaultLogger function which returns a default logger based on
environment, which is used by everything that takes an optional logger
in their config
- add createQueryClient test util function that uses a mock logger
- replace all `new QueryClient` calls with createQueryClient calls
- remove mockConsoleError and usages from tests, which are not necessary anymore

BREAKING CHANGE: remove setLogger
A
Anıl Anar committed
315f0cf4698640a77f1910d2e478893d3e41a258
Parent: fe98d53
Committed by GitHub <noreply@github.com> on 2/26/2022, 2:35:28 PM