Jonas A. Xavier
Jonas A. Xavier

Reputation: 115

Difference between "Add Line Comment" and "Toggle Line Comment" in Visual Studio Code

What is the difference between them? While I was testing both shortcuts, the behaviour was the same.

Add Line Comment or editor.action.addCommentLine in Linux is:

Ctrl+K Ctrl+C

And Toggle Line Comment or editor.action.commentLine in Linux is:

Ctrl+/

Upvotes: -1

Views: 459

Answers (1)

Jonas A. Xavier
Jonas A. Xavier

Reputation: 115

While doing new tests I found a little difference.

Their behaviour are the same in HTML, they just toggle the comment. But in JavaScript it is different. One adds comments, while the other toggle.

So it depends on the language.

Upvotes: 1

Related Questions