A little trick in Visual Studio Code

Matching braces in Visual Stduio CodeIf you have a bit of nesting and you want to make sure your braces match up, Visual Studio code (VSC) can help you with that.

Just drag the cursor over the left or right brace and it will highlight the corresponding brace. In the screenshot you can see the brace on the 2nd line and 5th lines are highlighted.

Here’s a second trick. You can quite easily collapse code blocks. On the left below is uncollapsed code. Now move the cursor between 3 and typedef and a down arrow should appear. Click it and it will collapse the block. It now shows a right arrow and you click it to expand it back.

Before Collapsing a block in C
Collapsed code

(Visited 22 times, 1 visits today)