Disabling automatic curly brackets after = in React Follow
I'm writing a React app in WebStorm, and am a novice at the topic. I've noticed that when typing = after certain declaration curly brackets instantly come up, when most of the time the parameter would require quotes around it. Below is a GIF that probably explains what I mean better:
i was wondering if there was a way to either change this feature to print quotes instead of curly brackets, or to turn it off completely?
Thanks in advance!
Please sign in to leave a comment.
You can set Add for JSX attributes: to None in Settings | Editor | Code Style | HTML | Other to disable them, or to Based on type to have either braces or quotes auto-completed depending on props type
That worked perfectly! Thank you!
Thank you very much!
THANK YOU!!!!! This issue was driving me CRAZY!!!!!!!!!!!!! Solved using above.
You can also set it to "Based on type". For strings it'll add quotes, and for for example, numbers, curly braces