📜  为什么 usestate 而不是变量会做出反应 - 无论代码示例

📅  最后修改于: 2022-03-11 14:57:33.294000             🧑  作者: Mango

代码示例1
You mainly use useState and not variables, because useState re-renders
the components that have changed when you modify the variable (this does 
not happen with variables)