Skip to content

Commit 71099a5

Browse files
authored
fix: route loader code example in docs (#9249)
1 parent 6b74214 commit 71099a5

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

contributors.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
- abhi-kr-2100
22
- Ajayff4
33
- alexlbr
4+
- andreiduca
45
- avipatel97
56
- awreese
67
- bavardage

docs/start/overview.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,9 +66,11 @@ createBrowserRouter(
6666
<Route
6767
path="dashboard"
6868
element={<Dashboard />}
69-
loader={fetch("/api/dashboard.json", {
70-
signal: request.signal,
71-
})}
69+
loader={({ request }) =>
70+
fetch("/api/dashboard.json", {
71+
signal: request.signal,
72+
})
73+
}
7274
/>
7375
<Route element={<AuthLayout />}>
7476
<Route

0 commit comments

Comments
 (0)