👨‍💻VS Code Shortcuts & Extensions

This is the dump of all the shortcuts and extension I use to super-charge my VS-code

Duplicating Lines

This is by far the most common and useful shortcut I use in vs-code

Shortcut: ⇧(Shift) + ⌥(Option) + ↑/↓ (macOS), Shift + Alt + ↑/↓ (windows)

This command will allow you to duplicate the line your cursor is on directly up or down.

HTML Tag wrap

This is a huge time-saver when you want to quickly enclose a big element with another tag.

Shortcut: ⌥(Option) + W (macOS), Alt + W (windows)

This command will create wrap <p> </p> tags around the block of code you highlighted.

Music Time

This is an extension that I recently installed and I really love it as it loads my entire Spotify Library straight into the sidebar of the IDE. I can control and select the playlists/music that I want directly from the sidebar without having to Alt-Tab to Spotify.

Go to VS Code's extension store and search for "Music-Time". You will have to log in to your Spotify account in order to synchronize your library.

Ad

Custom User Snippets

This is a guide for generating custom keyboard macros to streamline your coding/development experience.

Settings up Arrow function Macro for Javascript

1. Click on the Settings icon on the Bottom left-hand corner

Click on the Settings icon

2. Select 'User Snippet'

Select User Snippets

A prompt should pop-up prompting you to select the Language for the snippet.

Select 'Javscript.json' for creating your Javascript macro

Built-in example

You will see the above script that's already present. The example script is a custom macro to insert console.log() when you input lo

Each custom user snippet acts like a JSON object:

Placeholder text of the fields to fill up

Arrow Function Snippet

Code for arrow function snippet

By adding the above Object into the JSON, you will create an Arrow Function snippet with the shortcut arr to automatically insert () => {} without having to stretch your fingers around for the symbols.

Last updated

Was this helpful?