Browse Source

useTransition add semicolon (#5384)

main
Xiao Chuan 2 years ago
committed by GitHub
parent
commit
89ad6199ec
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      content/docs/hooks-reference.md

4
content/docs/hooks-reference.md

@ -580,7 +580,7 @@ Returns a stateful value for the pending state of the transition, and a function
```js
startTransition(() => {
setCount(count + 1);
})
});
```
`isPending` indicates when a transition is active to show a pending state:
@ -593,7 +593,7 @@ function App() {
function handleClick() {
startTransition(() => {
setCount(c => c + 1);
})
});
}
return (

Loading…
Cancel
Save