Quartz 5

Home

❯

develop

❯

react

❯

other

❯

Tips

Tips

Properties2
descriptionsetScore(score + 1);
tagsreact

Aug 28, 20261 min read

Tips

setState

setScore(score + 1);

不同于

setScore(s => s + 1);

连续调用场景

jsx 中 不能直接写switch

https://stackoverflow.com/questions/46592833/how-to-use-switch-statement-inside-a-react-component


Graph View

  • Tips
  • setState
  • jsx 中 不能直接写switch

Created with Quartz v5.0.0 © 2026

  • GitHub
  • Discord Community