Home > Software engineering >  Prevent autocomplete semicolon in JavaScript VSCode
Prevent autocomplete semicolon in JavaScript VSCode

Time:09-15

I'm using the Visual Studio Code. I never want autocomplete functions with semicolon in JS. Like when I type log TAB, it appears console.log(); with semicolon at the end.

How can I stop auto-complete semicolon at the end of JS functions.

CodePudding user response:

Go to Preferences of VSCode and search the semicolons. Then select ignore option. enter image description here

CodePudding user response:

To make VSCode insert console.log({}) instead of console.log({}); when you type log and then press tab, you need to edit the snippet's body.

  1. Press shift command p and type snippets
  2. Select Preferences: Configure User Snippets
  3. Select console.log().code-snippets
  4. Change line 23 from "console.log({$0});" to "console.log({$0})"
  • Related