Skip to content

Commit 0689252

Browse files
committed
Fix fetcher.submission reference in docs
1 parent 40d49e1 commit 0689252

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/hooks/use-fetchers.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ For example, imagine a UI where the sidebar lists projects, and the main view di
3838
+-----------------+----------------------------┘
3939
```
4040

41-
When the user clicks a checkbox, the submission goes to the action to change the state of the task. Instead of creating a "loading state" we want to create an "optimistic UI" that will **immediately** update the checkbox to appear checked even though the server hasn't processed it yet. In the checkbox component, we can use `fetcher.submission`:
41+
When the user clicks a checkbox, the submission goes to the action to change the state of the task. Instead of creating a "loading state" we want to create an "optimistic UI" that will **immediately** update the checkbox to appear checked even though the server hasn't processed it yet. In the checkbox component, we can use `fetcher.formData`:
4242

4343
```tsx
4444
function Task({ task }) {

0 commit comments

Comments
 (0)