Selecting block of code in Visual Studio Code

前端 未结 5 1273
星月不相逢
星月不相逢 2020-12-30 04:39

Is there a keyboard shortcut or an extension that would allow me to select a block of code? I\'d like to select everything between curly braces, between html tags, etc.

5条回答
  •  醉酒成梦
    2020-12-30 04:54

    Here are some useful shortcuts for working with blocks of code:

    alt + shift + ] to select current block of code.

    alt + shift + [ move cursor to beginning of code block and again to move to parent block.

    ctrl + ] move cursor from bracket to bracket.

    ctrl + shift + ] select block of code between brackets.

    See the Default keyboard shortcuts in Visual Studio under the Text Editor section for more. It takes some trial and error to find the right combo of shortcuts to suit your needs.

提交回复
热议问题