How to add a className to single .map item?

后端 未结 0 600
无人共我
无人共我 2021-01-28 17:32

I want to add className to a .map item, but only for the one which is clicked.

Tried useState ( {state ? "class" : ""} ) but it added class for all it

相关标签:
回答
  • 消灭零回复
提交回复
热议问题