Skip to content

Commit

Permalink
Export SetURLSearchParams type (#10444)
Browse files Browse the repository at this point in the history
  • Loading branch information
brophdawg11 committed May 15, 2023
1 parent 4ccdc11 commit 55482ec
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .changeset/set-search-params-type.md
@@ -0,0 +1,6 @@
---
"react-router-dom": patch
"react-router-native": patch
---

Export `SetURLSearchParams` type
2 changes: 1 addition & 1 deletion packages/react-router-dom/index.tsx
Expand Up @@ -916,7 +916,7 @@ export function useSearchParams(
return [searchParams, setSearchParams];
}

type SetURLSearchParams = (
export type SetURLSearchParams = (
nextInit?:
| URLSearchParamsInit
| ((prev: URLSearchParams) => URLSearchParamsInit),
Expand Down
2 changes: 1 addition & 1 deletion packages/react-router-native/index.tsx
Expand Up @@ -323,7 +323,7 @@ export function useSearchParams(
return [searchParams, setSearchParams];
}

type SetURLSearchParams = (
export type SetURLSearchParams = (
nextInit?:
| URLSearchParamsInit
| ((prev: URLSearchParams) => URLSearchParamsInit),
Expand Down

0 comments on commit 55482ec

Please sign in to comment.