Skip to content

Commit 244ac55

Browse files
authored
Import all dependencies
1 parent cf0aa6e commit 244ac55

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/router/framework/react/guide/router-context.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,13 +101,13 @@ export const Route = createFileRoute('/todos')({
101101
You can use it in your components with the `useRouteContext` hook:
102102

103103
```tsx
104-
import { useRouteContext } from '@tanstack/react-router'
104+
import { createFileRoute, useRouteContext } from '@tanstack/react-router';
105105

106106
export const Route = createFileRoute('/todos')({ component: Todos });
107107

108108
function Todos() {
109109
const routeContext = Route.useRouteContext();
110-
return <div>Todos from {routeContext.user.id}</div>
110+
return <div>Todos from {routeContext.user.id}</div>;
111111
}
112112
```
113113

0 commit comments

Comments
 (0)