Wojciech Słodziak
23bd5640c3
docs(examples/react): fix prefetch pagination logic when trying to quickly get to the last page ( #4564 )
...
* bugfix/pagination-example-fetch-next-page: fix basing decision whether next page should be refetched on information from two pages prior
In the useQuery call we set "keepPreviousData", so we must make sure that for fetching the next page we don't base our logic on the data from potentially two pages away.
If user would click very fast to get to the last page we would potentially load eleventh page and that could result in an error depending on the backend implementation.
* bugfix/pagination-example-fetch-next-page: update useEffect dependency array to reflect all used variables
2022-11-30 19:42:19 +01:00
Pierre-Luc Paquin
16000b8db0
docs: Adds Using Remix to SSR guide. ( #4566 )
2022-11-29 21:30:17 +01:00
Allan López
f364fbbf49
docs(useInfiniteQuery): add isRefetching to returned properties docs ( #4567 )
2022-11-29 21:13:57 +01:00
Michal Tecza
e5786715c6
docs: fix the example for queryClient.ensureQueryData ( #4572 )
2022-11-29 20:29:39 +01:00
Tanner Linsley
a1d65df46b
release: v4.18.1
2022-11-28 09:02:05 +00:00
henribru
f6d92a7a7f
fix(vue-query): use distributive omit to preserve union ( #4562 )
v4.18.1
2022-11-28 09:54:44 +01:00
Kevin Van Cott
70fd5bb463
chore(react-query-devtools): upgrade match-sorter-utils ( #4561 )
...
* Upgrade match-sorter-utils in react-query-devtools
match-sorter-utils should no longer have the bad transpilation problem anymore.
* run install
2022-11-28 08:02:57 +01:00
Tanner Linsley
43a5bac737
release: v4.18.0
2022-11-26 16:38:30 +00:00
Michal Tecza
1e0745a6cc
feat: queryClient.ensureQueryData ( #4544 )
...
v4.18.0
* feat: queryClient.ensureQueryData
* style: apply prettier
* refactor: make interface of `queryClient.ensureQueryData` similar to `queryClient.fetchData`
* docs: update docs of `ensureQueryData`
* style: apply prettier formatting
* docs: adjust options description
* refactor: improve types of ensureQueryData overloads
* Update packages/query-core/src/queryClient.ts
Co-authored-by: Dominik Dorfmeister <office@dorfmeister.cc>
2022-11-26 17:33:23 +01:00
henribru
e60e38ae0b
docs: update some things referring to old react-query ( #4557 )
...
* docs: update some things referring to old react-query
* Update overview of other TanStack libraries
* Use query-core for downloads badge
2022-11-26 16:51:05 +01:00
Zakuru San
f7008433ae
docs(comparison): Apollo Client V3 Reactive Variables ( #4528 )
...
https://www.apollographql.com/docs/react/local-state/reactive-variables/
In the V3 of Apollo client is it mention that all type of syntax are supported not only GQL thanks to Reactive Variable feature
2022-11-26 11:15:47 +01:00
Michal Tecza
6b9549f07c
docs: fix docs for queryClient.getQueryData ( #4545 )
2022-11-26 09:53:50 +01:00
Damian Osipiuk
11f08c37d5
chore: fix prettier script, format examples ( #4534 )
2022-11-26 07:37:16 +01:00
Tanner Linsley
65841a6ec0
release: v4.17.1
2022-11-26 00:12:29 +00:00
Aleksandr Semenov
379297a74b
fix(vue-query): export proper useQuery return type ( #4513 )
...
v4.17.1
* fix(vue-query): export useQuery return type
* fix(vue-query): export useInfiniteQuery return type
* fix(vue-query): re-export UseQueryDefinedReturnType
Co-authored-by: Aleksandr Semenov <juvs@ecwid.com>
Co-authored-by: Damian Osipiuk <osipiukd+git@gmail.com>
2022-11-26 01:03:12 +01:00
Gustavo Lima
1e998d34b0
docs: fix typo in parallel-queries.md ( #4529 )
2022-11-21 22:25:04 +01:00
Michal Tecza
b79f45806c
test: stabilize some useQuery and useInfiniteQuery tests ( #4526 )
...
* test: stabilize the test for overriding the cursor in the fetchNextPage callback
* test: stabilize the test for error when a selector throws
* style: apply formatting
* test: stabilize the test for variables in a query function
2022-11-20 15:55:14 +01:00
Michal Tecza
d37594a99a
test: stabilize useQuery tests ( #4525 )
...
* test: stabilize the test for onSettled callback
* test: stabilize the test re-renders when tracking but not using props
* test: stabilize the test for onSuccess callback on disabled query
* test: stabilize the test for online/offline scenario
2022-11-19 19:01:40 +01:00
airman5573
899773a486
docs: Add a missing closing bracket ( #4509 )
2022-11-15 00:21:21 +01:00
Tanner Linsley
0c27968989
release: v4.17.0
2022-11-14 00:36:37 +00:00
Damian Osipiuk
c2447a9fd0
feat(vue-query): client persister ( #4469 )
...
v4.17.0
* feat: vue-query client persister
* fix: change devtools link to tanstack query
* chore: update repository in package.json
* docs: persister example
* feat: propagate isRestoring trough queryClient
* fix: useIsFetching allow refs as args
* fix: allow ref args for useIsMutating
* test: add test for isRestoring
* chore: fix formatting
* fix(vue-query): suspense unsubscribe from watch
* feat: persistent useQueries
* chore: examples formatting
* test: persister
* chore: fix lint errors
* chore: fix weird lint errors
2022-11-14 01:32:51 +01:00
Tanner Linsley
9009b0d4f1
release: v4.16.1
2022-11-13 19:04:23 +00:00
Naymi
9584a6a6a6
fix(vue-query): useQueries options allow empty array ( #4505 )
v4.16.1
2022-11-13 19:12:44 +01:00
Dante
f65e7af10f
test: add useQueries with suspense tests ( #4502 )
...
* test: add useQueries with suspense tests
shouldn't unmount before all promises fetched
should suspend all queries in parallel - global configuration
* fix should suspend all queries in parallel - global configuration - remove query suspense option
Co-authored-by: Dominik Dorfmeister <office@dorfmeister.cc>
2022-11-13 10:33:18 +01:00
Tanner Linsley
409a684534
release: v4.16.0
2022-11-13 07:59:54 +00:00
Stefan Djokovic
d99d94e524
feat(devtools): add 'copy' button in devtools ( #4468 )
...
v4.16.0
* feat(devtools): add copy object data explorer
* fix: address code comments
* fix: add logs to investigate iframe copy issue
* feat: add checkmark on copy
* add: error state
* add: test
* fix: test import
* fix: layouts and use superjson
* fix: test comment
* fix: typing and onclick only on nocopy
* prettier
* fix: test error react17
* fix: format test
* fix: test copy and add await
Co-authored-by: Dominik Dorfmeister <office@dorfmeister.cc>
2022-11-13 08:55:01 +01:00
Tanner Linsley
1883be39db
release: v4.15.1
2022-11-13 07:54:27 +00:00
Dominik Dorfmeister
32b3aac537
fix: lock dependency of @tanstack/match-sorter-utils to 8.1.1 ( #4501 )
...
v4.15.1
because the newer versions have trouble with esm and webpack4
RELEASE_ALL
2022-11-13 08:50:11 +01:00
Tanner Linsley
2bcc2a9280
release: v4.15.0
2022-11-12 07:32:04 +00:00
Dominik Dorfmeister
9d9aea5fb1
feat(react-query): suspense for useQueries ( #4498 )
...
v4.15.0
* feat: suspense for useQueries
* generics for fetchOptimistic
* tests: useQueries suspense
2022-11-12 07:59:35 +01:00
Tanner Linsley
41e2af25e8
release: v4.14.8
2022-11-11 20:13:06 +00:00
Minami
d5bf345d98
fix(react-query-devtools): unset padding for resetting after closed ( #4477 )
...
v4.14.8
* fix(devtools): unset padding for resetting after closed
* fix(devtools): restore inline padding styles after closed
* fix(devtools): undo unnecessary style tag
* fix(devtools): add test
2022-11-11 21:09:12 +01:00
SeanBarker182
54f16f69ff
docs: Adds a missing square bracket ( #4488 )
2022-11-11 13:06:07 +01:00
Tanner Linsley
f079297ff8
release: v4.14.7
2022-11-11 11:57:38 +00:00
Eliya Cohen
82adc95c24
fix(eslint-plugin-query): run exhaustive dep check on referenced query key ( #4480 )
...
v4.14.7
* run exhaustive dep check on referenced query key
* fix various eslint issues
2022-11-11 12:53:15 +01:00
Abdullah Al Sadi
67ddf17b65
docs: Update disabling-queries.md ( #4472 )
...
fix a typo
2022-11-11 09:59:24 +01:00
Damian Osipiuk
58f3cec654
docs(vue-query): vue2, nuxt3 examples ( #4384 )
2022-11-11 09:58:57 +01:00
Tanner Linsley
3c1959d4a8
release: v4.14.6
2022-11-11 08:48:45 +00:00
Eliya Cohen
933cd410ae
fix(eslint-plugin): false positive for factory functions ( #4497 )
...
v4.14.6
* fix false positive for factory functions
* add more test
* lint fix
* format
* remove unnecessary conditional
* empty commit (flaky test)
* empty commit (flaky test)
2022-11-11 09:43:30 +01:00
Minami
fa681126f9
docs(guides/prefetching): prefer object syntax ( #4492 )
2022-11-09 15:59:53 +01:00
Bennett Dams
b421e74ca2
docs(eslint-plugin-query): Prefer dev install ( #4489 )
...
This change adds the CLI flags to install the ESLint plugin as a dev dependency instead of a normal dependency.
2022-11-09 11:23:49 +01:00
Daniel Reinoso
74e0ee2ca2
docs: typo in "immutable" ( #4486 )
...
Fix typo in updates-from-mutation-responses.md
2022-11-08 15:46:07 +01:00
Dominik Dorfmeister
1f441b1427
docs: immutability
2022-11-08 12:07:27 +01:00
Dominik Dorfmeister
60f460f1af
docs: immutability
2022-11-08 12:06:29 +01:00
allcontributors[bot]
350aba5202
add balazsmatepetro as a contributor for code ( #4482 )
...
* update README.md [skip ci]
* update .all-contributorsrc [skip ci]
Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com>
2022-11-08 11:40:59 +01:00
Dominik Dorfmeister
a0a8ada275
chore: fix allcontributors
2022-11-08 10:51:52 +01:00
박찬혁
6a6e2c1a68
docs: fix suspense link ( #4481 )
2022-11-08 08:06:02 +01:00
Tanner Linsley
c27dd7a2a6
release: v4.14.5
2022-11-06 15:46:01 +00:00
Michal Tecza
c45c1bfc4c
fix(query-core): make isRefetching false when fetching next/previous page in an infinite query ( #4465 )
...
v4.14.5
* fix: make isRefetching false when fetching next/previous page in an infinite query
* Update packages/query-core/src/infiniteQueryObserver.ts
Co-authored-by: Dominik Dorfmeister <office@dorfmeister.cc>
* Apply suggestions from code review
* prettier
Co-authored-by: Dominik Dorfmeister <office@dorfmeister.cc>
2022-11-06 16:40:33 +01:00
Dominik Dorfmeister
4861200630
refactor(core): derive meta from options ( #4463 )
...
this simplifies code because we don't need to pass meta around manually; we can keep the same public interface with a getter
2022-11-06 16:26:34 +01:00