Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio Code Autocomplete Add Parentheses After Method in .js File

When I type console.lo in a .js file in Visual Studio Code, I can hit Enter, and autocomplete will change my line to console.log. However, I would also like autocomplete to add parentheses. This question was already asked using the Go programming language. I tried adding js.useCodeSnippetsOnFunctionSuggest as well as javascript.useCodeSnippetsOnFunctionSuggest. Neither of these work. I also tried useCodeSnippetsOnMethodSuggest as suggested here, but that didn't work either. What am I doing wrong?

like image 380
Alon Avatar asked Sep 17 '25 06:09

Alon


1 Answers

I fixed this by searching for "Complete Function Calls" in VS Code's settings, and checking JavaScript > Suggest: Complete Function Calls. Thanks Mark for the suggestion.

like image 169
Alon Avatar answered Sep 19 '25 23:09

Alon



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!