🚀 Thank you to vscode-js-console-utils
Easily insert and remove log statements from (most) popular languages, by @youngkidwarrior
This extension is available for free in the Visual Studio Code Marketplace
👉 With selection:
- Highlight a variable (or really any text)
- Press Cmd+Shift+L
- The output (on a new line) will be: console.log('variable: ', variable);
💡 Without selection:
- Press Cmd+Shift+L
- The output (on the same line) will be: console.log();
❌ To remove logs:
- Press Cmd+Shift+D
- This will delete all console.log statements in the current document