92

Example: trying to type return res.data

after typing the . it autocompletes to return resizeBy.

Have already turned off autocomplete on enter, and don't want to turn off editor.quickSuggestions completely as I still like the menu coming up (just not taking over too much).

Can't find very much about this online at all.

J. Scott Elblein
  • 4,013
  • 15
  • 58
  • 94
dan674
  • 1,848
  • 2
  • 15
  • 21
  • check this, maybe this is what u are looking for: https://stackoverflow.com/questions/32911977/prevent-autocomplete-in-visual-studio-code – G43beli Mar 23 '18 at 10:36
  • thanks - I had a look at that earlier but none of the settings actually apply. i'm happy to keep the visual suggestions, just want to disable the hotkey to accept them (I need something like editor.acceptSuggestionOnDot) – dan674 Mar 23 '18 at 11:22
  • 5
    Possible duplicate of [Visual Studio Code autocomplete when I press "." key. Any way to disable?](https://stackoverflow.com/questions/48609354/visual-studio-code-autocomplete-when-i-press-key-any-way-to-disable) – Alex Mar 23 '18 at 19:24

2 Answers2

150

place this in your settings.json file:

"editor.acceptSuggestionOnCommitCharacter": false,

To open settings.json file:

  1. cmd + , or ctrl +,
  2. scroll down until you see Files: Associations
  3. Click on edit in settings.json
  4. paste the code above and save.
J. Scott Elblein
  • 4,013
  • 15
  • 58
  • 94
Nick Daria
  • 1,660
  • 1
  • 13
  • 11
  • 4
    Trying to go from Atom to Code, and this was doing my head in; especially when trying to spread data within JS. Thanks! – theOneWhoKnocks Aug 03 '20 at 16:09
  • 2
    Additional to this, if you want to stop the popover from appearing when entering a dot, then set `"editor.suggestOnTriggerCharacters": false` – Rafael Schimassek Jun 05 '22 at 21:32
8
  1. open vs code editor.
  2. under left hand corner => click setting
  3. "text editor" => suggestion.
  4. uncheck the Accept Suggestion On Commit Character (it could be placed on the first line of suggestion)
Alessio
  • 3,404
  • 19
  • 35
  • 48
xiaonan
  • 81
  • 1
  • 1