What's Changed
- Add use client directive for client components exports by @huozhi in #2696
- remove the 'use client' directive and add client-only to useSWR entry. by @promer94 in #2705
- fix: should serialize subscription fn key by @promer94 in #2711
- build(deps-dev): bump word-wrap from 1.2.3 to 1.2.4 by @dependabot in #2720
- fix: only make data and error update as a non-blocking transition by @promer94 in #2691
- build: generate d.mts for for .mjs, so typescript could resolve types correctly by @promer94 in #2695
- fix(infinite): Fix the ability to use preload along with useSWRInfinite by @agadzik in #2723
- fix: Ensure that using preload with useSWRInfinite returns back an array of data by @agadzik in #2726
- fix: preload request should be consumed within
revalidate
to supportparallel
option by @promer94 in #2727 - Fix the issue that useSWR revalidation isn't triggered if the useSWR call happens after mutation by @Ponyets in #2731
- fix(mutate): fix types of mutate/trigger; make mutate/trigger always return the result of fetcher by @Ponyets in #2708
- build(deps-dev): bump tough-cookie from 4.1.2 to 4.1.3 by @dependabot in #2735
- build(deps-dev): bump json5 from 2.2.1 to 2.2.3 by @dependabot in #2736
- docs: use isLoading instead of !data by @pawfa in #2734
New Contributors
- @agadzik made their first contribution in #2723
- @Ponyets made their first contribution in #2731
- @pawfa made their first contribution in #2734
Full Changelog: v2.2.0...v2.2.1