Skip to content

Commit d000ca8

Browse files
committed
doc: Update message in react-router shorthand adapter
1 parent a64020a commit d000ca8

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

packages/nuqs/adapters/react-router.d.ts

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@
33
// Other module resolutions strategies will look for the `exports` in `package.json`,
44
// but with `node`, TypeScript will look for a .d.ts file with that name at the
55
// root of the package.
6-
// This default react-router adapter is for react-router v6. If you are using
7-
// react-router v7, please use adapters/react-router/v7
6+
//
7+
// Note: this default react-router adapter is for react-router v6.
8+
// If you are using react-router v7, please import from `nuqs/adapters/react-router/v7`
89

910
export * from '../dist/adapters/react-router'

packages/nuqs/src/adapters/react-router.ts

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// Note: this default react-router adapter is for react-router v6.
2+
// If you are using react-router v7, please import from `nuqs/adapters/react-router/v7`
3+
14
import { useNavigate, useSearchParams } from 'react-router-dom'
25
import { renderQueryString } from '../url-encoding'
36
import type { AdapterOptions } from './defs'

0 commit comments

Comments
 (0)