1

My question is very easy and it is possible that this is a stupid question but I need your help. I have tried to develop a component with a function where I implemented a require function. In this last function, I included a state where a "select" option send the value (the path of the css file) to update this state. The value depend the choice of the user. So, it partially works because when I come back to an option that I picked a few seconds ago, the require function doesn't work anymore. I am not sure that was the best option. I am a beginner. Can someone explain me the reason why "require()" stops to work and which is the best way to resolve this functionality please ?

Comments
Add Comment