Skip to content

Commit

Permalink
Merge pull request #33 from mohamednehad450/tanstack-query-update
Browse files Browse the repository at this point in the history
Tanstack query update
  • Loading branch information
alan2207 authored Nov 13, 2023
2 parents 4883715 + 4354631 commit 962cdcb
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 19 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-query-auth",
"version": "2.1.2",
"version": "2.2.0",
"author": "alan2207",
"license": "MIT",
"repository": "alan2207/react-query-auth",
Expand All @@ -26,7 +26,7 @@
"size": "size-limit"
},
"peerDependencies": {
"@tanstack/react-query": "^4.24.6",
"@tanstack/react-query": ">=4.24.6",
"react": ">=16.8.0"
},
"husky": {
Expand All @@ -46,7 +46,7 @@
],
"devDependencies": {
"@size-limit/preset-small-lib": "^8.2.4",
"@tanstack/react-query": "^4.24.6",
"@tanstack/react-query": "^5.7.2",
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^13.4.0",
"@testing-library/react-hooks": "^8.0.1",
Expand Down
6 changes: 5 additions & 1 deletion src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,11 @@ export function configureAuth<
UseQueryOptions<User, Error, User, QueryKey>,
'queryKey' | 'queryFn'
>
) => useQuery(userKey, userFn, options);
) => useQuery({
queryKey: userKey,
queryFn: userFn,
...options
});

const useLogin = (
options?: Omit<
Expand Down
24 changes: 9 additions & 15 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -796,18 +796,17 @@
"@size-limit/esbuild" "8.2.4"
"@size-limit/file" "8.2.4"

"@tanstack/query-core@4.24.6":
version "4.24.6"
resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-4.24.6.tgz#8f102bc922308f0c6c5ddea34fe253688314265a"
integrity sha512-Tfru6YTDTCpX7dKVwHp/sosw/dNjEdzrncduUjIkQxn7n7u+74HT2ZrGtwwrU6Orws4x7zp3FKRqBPWVVhpx9w==
"@tanstack/query-core@5.7.2":
version "5.7.2"
resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-5.7.2.tgz#c4a994d6f2b0a6901741a805c32da94db964880d"
integrity sha512-vPYoNCOI8W+jFLnyEAYQL7/qURE7XzVE/TvkmNSko8LU55jFshee342p4GNFOTsYFgJty7Da5bw4m2P3vaKWMw==

"@tanstack/react-query@^4.24.6":
version "4.24.6"
resolved "https://registry.yarnpkg.com/@tanstack/react-query/-/react-query-4.24.6.tgz#ec406e59314ae13d31a2c82eed0043bb0b67ba2e"
integrity sha512-pbJUVZCS4pcXS0kZiY+mVJ01ude0GrH5OXT2g9whcqSveRG/YVup/XdA9NdRpSMGkP2HxDRxxRNsTXkniWeIIA==
"@tanstack/react-query@^5.7.2":
version "5.7.2"
resolved "https://registry.yarnpkg.com/@tanstack/react-query/-/react-query-5.7.2.tgz#28a697ed9b8e5ae5c19f79a692180e819555c91f"
integrity sha512-NMsfz0Wd3VPDvSpX9sw2x07r0kf9HwuAlNNHQvwMUHM7EcuVN/LYmlmTe40dWER1c/92Jhc5LODdtW0PyvHsFg==
dependencies:
"@tanstack/query-core" "4.24.6"
use-sync-external-store "^1.2.0"
"@tanstack/query-core" "5.7.2"

"@testing-library/dom@^8.5.0":
version "8.19.1"
Expand Down Expand Up @@ -4356,11 +4355,6 @@ url-parse@^1.5.3:
querystringify "^2.1.1"
requires-port "^1.0.0"

use-sync-external-store@^1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz#7dbefd6ef3fe4e767a0cf5d7287aacfb5846928a"
integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==

v8-to-istanbul@^9.0.1:
version "9.1.0"
resolved "https://registry.yarnpkg.com/v8-to-istanbul/-/v8-to-istanbul-9.1.0.tgz#1b83ed4e397f58c85c266a570fc2558b5feb9265"
Expand Down

0 comments on commit 962cdcb

Please sign in to comment.