How to apply styles to a child class in JSS

后端 未结 2 757
有刺的猬
有刺的猬 2020-12-11 19:40

I\'m using React, Material UI with JSS and React Router.

I\'m hooking in to to apply an active class like:



        
2条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-11 20:21

    It does not work due to class name ".btn" because the root class "active" after rendering of React will not have the same class name and it cannot found out it.

    just set {classes.btn}

    
    

提交回复
热议问题