Skip to content

Commit

Permalink
chore: fix a typo in startTransition docs (#7361)
Browse files Browse the repository at this point in the history
  • Loading branch information
AminDannak authored Dec 16, 2024
1 parent 31456db commit d4d1683
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/content/reference/react/startTransition.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ function TabContainer() {

* You can wrap an update into a Transition only if you have access to the `set` function of that state. If you want to start a Transition in response to some prop or a custom Hook return value, try [`useDeferredValue`](/reference/react/useDeferredValue) instead.

* The function you pass to the of `startTransition` is called immediately, marking all state updates that happen while it executes as Transitions. If you try to perform state updates in a `setTimeout`, for example, they won't be marked as Transitions.
* The function you pass to `startTransition` is called immediately, marking all state updates that happen while it executes as Transitions. If you try to perform state updates in a `setTimeout`, for example, they won't be marked as Transitions.

* You must wrap any state updates after any async requests in another `startTransition` to mark them as Transitions. This is a known limitation that we will fix in the future (see [Troubleshooting](/reference/react/useTransition#react-doesnt-treat-my-state-update-after-await-as-a-transition)).

Expand Down

0 comments on commit d4d1683

Please sign in to comment.