Skip to content

Commit 4ac5d24

Browse files
committed
docs: clarify that useState setter triggers a re-render in Quick Start
1 parent 8efce78 commit 4ac5d24

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/content/learn/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@ function MyButton() {
336336
}
337337
```
338338
339-
React will call your component function again. This time, `count` will be `1`. Then it will be `2`. And so on.
339+
Calling `setCount()` tells React that its state has changed, which triggers a re-render. React will call your component function again. This time, `count` will be `1`. Then it will be `2`. And so on.
340340
341341
If you render the same component multiple times, each will get its own state. Click each button separately:
342342

0 commit comments

Comments
 (0)