Skip to content

Commit a53f632

Browse files
authored
docs: Return Statement (TanStack#2713)
1 parent f7854e0 commit a53f632

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

docs/src/pages/guides/mutations.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@ Here's an example of a mutation that adds a new todo to the server:
99

1010
```js
1111
function App() {
12-
const mutation = useMutation(newTodo => axios.post('/todos', newTodo))
12+
const mutation = useMutation(newTodo => {
13+
return axios.post('/todos', newTodo)
14+
})
1315

1416
return (
1517
<div>

0 commit comments

Comments
 (0)