Skip to content

Commit 1b69e16

Browse files
docs: clarify that Transition Actions can be asynchronous
1 parent 046f17d commit 1b69e16

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎src/content/reference/react/useTransition.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1684,7 +1684,7 @@ startTransition(() => {
16841684
});
16851685
```
16861686
1687-
The function you pass to `startTransition` must be synchronous. You can't mark an update as a Transition like this:
1687+
The Action you pass to `startTransition` can be asynchronous. However, state updates scheduled in a `setTimeout` callback are not marked as Transitions, because the callback runs after the `startTransition` call has finished:
16881688
16891689
```js
16901690
startTransition(() => {

0 commit comments

Comments
 (0)