How to stop IntelliJ from placing semicolons after an auto-completion?
Hello, so this is annoying me because I use tab to leave brackets etc and when I use auto-complete and a semicolon is being placed after the bracket this happens:
as you can see in the first statement I'm having problems "jumping" over the semicolon while when I dont use the auto-completion in the second statement (and don't get the semicolon automatically) it's way easier to navigate through it with tab. I know that there is the shift-enter shortcut but I don't really want to develop a habbit of using it so often because I can imagine trying to do that when working with my other IDE's can become quite annoying. I searched through the options but did not find any option do disable that behavior. Does anyone know a way to get around this?
Please sign in to leave a comment.
There is no option to disable the semicolons. I can only suggest to use the Complete current statement action or Shift+Enter.
We'll consider improving the Tab behavior instead, please follow https://youtrack.jetbrains.com/issue/IDEA-211180 for updates.
Ok thanks.
What I found that could help me with the semicolons placed on save, at least for the JS/React side, was to activate Reformat code option on save and then from Languages & Frameworks -> Javascript -> Prettier activate the On 'Reformat Code' action and 'On save'; So now, on save, it first rearranges the code and ads the semicolon and then prettifies it as expected.