How to comment multiple lines in Visual Studio Code?

后端 未结 30 1866
感情败类
感情败类 2020-11-28 00:23

I cannot find a way to comment and uncomment multiple lines of code in Visual Studio Code.

Is it possible to comment and uncomment multiple lines in Visual Studio Co

相关标签:
30条回答
  • 2020-11-28 01:19

    As of now (version 1.18.0), you can check keyboard shortcuts by going to File > Preferences > Keyboard shortcuts. Here you can search for comment related shortcuts.

    For users who are coming from Sublime Text or likes to have Ctrl+Shift+/, you can make the change from the above mentioned setting or simply install the Sublime Text Keymap extension by Microsoft.

    0 讨论(0)
  • 2020-11-28 01:22

    For me to comment I use:

    Ctrl + k, Ctrl + c

    and to uncomment:

    Ctrl + k, Ctrl + u

    I am using ubuntu 18.0.4

    0 讨论(0)
  • 2020-11-28 01:24

    You can find the shortcut in the Edit menu :

    Edit > Toggle Block Comment => Shift-Alt-A

    0 讨论(0)
  • 2020-11-28 01:24

    1.Select the text, Press Cntl + K, C to comment (Ctr+E+C ) 2.Move the cursor to the first line after the delimiter // and before the Code text. 3.Press Alt + Shift and use arrow keys to make selection. ... 4.Once the selection is done, press space bar to enter a single space.

    0 讨论(0)
  • 2020-11-28 01:25

    CTRL + SHIFT + A For Red Hat,centos

    • Select item
    • then CTRL+SHIFT+A
    0 讨论(0)
  • 2020-11-28 01:26

    The keyboard shortcut to comment multiple in Windows is shift+alt+A.

    0 讨论(0)
提交回复
热议问题