Answer the question
In order to leave comments, you need to log in
How to use react js to apply a class on button click?
It is necessary that when the button is clicked, a new class is applied to the container
Answer the question
In order to leave comments, you need to log in
put a variable in the state by clicking on the button, change it, in the rendering of the className component, you do it depending on the variable in the state
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question