Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

Commit b52feb3

Browse files
authored
Update use-react-router.ts
1 parent fddb411 commit b52feb3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/use-react-router.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const useRouter: UseRouter = <T = {}>(): RouteComponentProps<T> => {
1717
const forceUpdate: VoidFunction = useForceUpdate();
1818
const routerContext: RouteComponentProps<T> = useContext(__RouterContext);
1919
if (!routerContext) {
20-
throw new Error('use-react-router may only be used within a react-router context.');
20+
throw new Error('use-react-router may only be used with react-router@^5.');
2121
}
2222
useEffect(
2323
(): VoidFunction =>

0 commit comments

Comments
 (0)