How can I add multiple className's to react component?

后端 未结 4 1476
时光说笑
时光说笑 2021-02-07 03:44

I need to add one className to a component which is being passed down from the parent, and another className that doesn\'t have anything to do with its parent, but with the comp

4条回答
  •  时光说笑
    2021-02-07 04:29

    Combo of string and props class is here

    className={`${props.myClass} MyStringClass`}
    

提交回复
热议问题