Releases: vercel/swr
Releases Β· vercel/swr
1.0.0-beta.15
1.0.0-beta.14
Patches
- Chore: add test for callback setSize: #1373
- Fix: cache is missing on server side: #1377
- Rm deprecated warning: #1374
- Add basic test for node env: #1378
- [Infinite] Return current data if failed to resolve pages from cache when setting size: #1379
- Rename revalidateWhenStale: #1381
Credits
Huge thanks to @huozhi for helping!
1.0.0-beta.13
Major Changes
- New useSWRConfig API and remove createCache: #1361
- Rename middlewares option to use: #1368
- Rename fallbackValues to fallback; rename initialData to fallbackData: #1370
Minor Changes
Patches
- Improve tests for cache provider: #1369
Credits
Huge thanks to @huozhi and @pacocoursey for helping!
1.0.0-beta.12
1.0.0-beta.11
Minor Changes
- Export
unstable_serialize
from SWR: #1337
Patches
- Fix type of MutatorCallback: #1342
- Improvement: return stale data then revalidate when setting size of
useSWRInfinite
: #1343 - Lint-staged: remove lint, fix prettier: #1347
- Local devdelopment with examples: #1330
- Fix: alias swr in next client bundle on dev mode: #1349
- Refactor code structure: #1350
Credits
Huge thanks to @huozhi for helping!
1.0.0-beta.10
Major Changes
- BREAKING: Deprecate
revalidate
withmutate
: #1332
Minor Changes
- Improvement: ensure
useSWRInfinite
reusesuseSWR
cache: #1341
Patches
- Code refactoring: #1307
- Add package.json to module exports: #1313
- Fix config being ignored when fetcher is null: #1311
- Reset cache between tests: #1309
- Refine the infinite hook: #1315
- Test: add a test for getInfiniteKey with current data: #1319
- Update bunchee 1.6.2: #1323
- Chore: update useSWRInfinite import: #1326
- Upgrade bunchee, reduce node_modules size: #1329
- Build(deps): bump path-parse from 1.0.6 to 1.0.7: #1334
Credits
Huge thanks to @huozhi, @heysailor, @koba04, and @eric-hc for helping!
1.0.0-beta.9
Major Changes
- Move infinite types to swr/infinite and deprecate old ones: #1272
- Drop legacy types: #1276
- Breaking: drop the default fetcher: #1304
Minor Changes
- Feat: add getInfiniteKey to mutate the cache for useSWRInfinite: #1257
- Rename isDocumentVisible to isVisible: #1308
Patches
- Fix types generate: #1266
- Add test case that covers #1286: #1297
- Enhance: simplify deno detection: #1299
- Refine createCache: #1283
- Fix useSWRInfinite doesn't revalidate the first page: #1301
- Code structure refactoring: #1303
Credits
1.0.0-beta.8
Major Changes
- Sub-packages and immutable hook: #992
Patches
- Add condition to check if window.addEventListener exists for React Native compatibility: #1234
- Chore: bump typescript to use ts-expect-error instead of ts-ignore: #1239
- Enhance: add $ prefix for non-major keys: #1174
- Fix: fail accessing navigator on Node: #1254
- Chore: fix to run the build script multiple times: #1255
- Test: run concurrent rendering tests with React v18 alpha: #1259
- Fix: ignore .d.ts in dist/ for ESLint: #1258
- Enhance: use ts for testing: #1260
- Chore: add watch scripts for sub packages to build them: #1261
- Fix typo in use-swr: #1267
- Chore: fix type SWRHookWithdMiddleware to SWRHookWithMiddleware: #1268
Credits
Huge thanks to @javascripter, @koba04, @huozhi, and @pa-rang for helping!
1.0.0-beta.7
Minor Changes
Patches
- Test: refactor use-swr-loading.test.tsx: #1057
- Test: refactor use-swr-local-mutation.test.tsx: #1059
- Fix #1056: #1058
- Test: refactor use-swr-offline.test.tsx: #1063
- Allow setting the generic on mutate(): #1069
- Read cache during render: #794
- Code refactoring: #1077
- Add --no-sourcemap: #1079
- Fix mutate: #1075
- Revert #1024: #1085
- Fix: race problem when in dedupingInterval: #1088
- Bug fixes: #1096
- Test: refactor use-swr-refresh.test.tsx: #1103
- Docs: optimistic UI examples comments more clearer: #1102
- Fix setting
null
cache inuseSWRInfinite
: #1110 - Test: refactor use-swr-revalidate.test.tsx: #1111
- Test: refactor use-swr-suspense.test.tsx: #1113
- Build: upragde bundler: #1121
- Replace deprecated types with latest types in axios-typescript example: #1128
- Add saveData to slowConnection: #1130
- Clean code: #1145
- Update bound mutate readme: #1127
- Code optimizations: #1150
- Enhance: support exports field: #1154
- Fix global mutate generic: #1159
- Build(deps): bump hosted-git-info from 2.8.5 to 2.8.9: #1164
- Enhance: upgrade ts lint config: #1169
- Build(deps): bump browserslist from 4.16.3 to 4.16.6: #1181
- Fix: autocomplete suggestions example: #1183
- Build(deps): bump ws from 7.4.2 to 7.4.6: #1184
- Update README.md: #1203
- Fix typo in placeholder: #1206
- Update package.json: #1205
- Build(deps): bump acorn from 6.3.0 to 6.4.2: #1210
- Build(deps): bump y18n from 4.0.0 to 4.0.3: #1209
- Build(deps): bump lodash from 4.17.19 to 4.17.21: #1208
- Build(deps): bump glob-parent from 5.1.0 to 5.1.2: #1207
- Add codeowner @huozhi: #1221
Credits
Huge thanks to @huozhi, @koba04, @promer94, @nstepien, @MoonBall, @mkrtchian, @eunsukimme, @Tak-Iwamoto, @meeoh, and @teinett for helping!