Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

disable preview when go to definition in vscode

When I ever click to go to a definition in vscode I just want to go there, I do not want the overlay.

Can I disable it?

enter image description here

like image 426
dagda1 Avatar asked Jun 22 '18 17:06

dagda1


People also ask

How do you enable to define in VS Code?

Go to Definition# If a language supports it, you can go to the definition of a symbol by pressing F12. Tip: You can jump to the definition with Ctrl+Click or open the definition to the side with Ctrl+Alt+Click.

How do I enable side preview in VS Code?

To switch between views, press Ctrl+Shift+V in the editor. You can view the preview side-by-side (Ctrl+K V) with the file you are editing and see changes reflected in real-time as you edit.


2 Answers

This happens when multiple definitions were found, modify settings.json

"editor.gotoLocation.multipleDefinitions": "goto" 


enter image description here

like image 52
Dkra Avatar answered Sep 27 '22 21:09

Dkra


So I was looking for the same thing and since I found this post and it wasn't answered yet, I thought I could do it.

vscode won't peek preview definitions anymore after you add this to your JSON user settings file:

"editor.gotoLocation.multiple": "goto" 
like image 20
Gabriel Fiori Avatar answered Sep 27 '22 22:09

Gabriel Fiori