vscode console.log快捷键

在 Visual Studio Code 中,您可以使用快捷键「Ctrl + Shift + P」(Mac 用户请使用「Cmd + Shift + P」)打开命令面板,然后输入「Editor: Insert Console.log」即可快速插入「console.log」代码。此快捷键已内置于 Visual Studio Code 中,无需安装额外的插件。

配置文件

{

// Place your snippets for javascript here. Each snippet is defined under a snippet name and has a prefix, body and

// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:

// 1, 2 for tab stops, 0 for the final cursor position, and {1:label}, ${2:another} for placeholders. Placeholders with the

// same ids are connected.

// Example:

// https://blog.csdn.net/ABB_818/article/details/124005658

"Print to log": {

"prefix": "log",

"body": [

"console.log('%c%s', 'color:#cb3a56', 'mingLog:--' + '$1');"

// "console.log('$1');",

"$2"

],

"description": "Log output to "

}

}

相关推荐
●VON1 小时前
鸿蒙 PC Markdown 编辑器内核:在 ArkWeb 中离线运行 CodeMirror 6
安全·华为·编辑器·harmonyos·鸿蒙
●VON10 小时前
鸿蒙 PC Markdown 编辑器存储安全:AtomicFile 原子提交与故障注入
安全·华为·编辑器·harmonyos·鸿蒙
●VON19 小时前
鸿蒙 PC Markdown 编辑器 Alpha 评审:如何用退出条件判断阶段完成
网络·安全·华为·编辑器·harmonyos·鸿蒙
MGS浪疯19 小时前
我用 WorkBuddy 做了一个能记住前文的 AI 小说编辑器
人工智能·编辑器·腾讯云·腾讯云ai代码助手·workbuddy开发者分享季·codebuddy开发者分享季
●VON20 小时前
鸿蒙 PC Markdown 编辑器 Bridge 协议:原生外壳与 Web 内核的状态同步
前端·华为·编辑器·harmonyos·鸿蒙
Irene19911 天前
怎么设置 PyCharm 使用 VSCode 的快捷键,推荐保留的原生快捷键(特色功能不建议覆盖,否则丧失效率优势)Ctrl+Alt+L:代码格式化
vscode·pycharm·快捷键
●VON1 天前
鸿蒙 PC Markdown 编辑器原生右键弹层兼容
安全·华为·编辑器·harmonyos·鸿蒙
放学校门口见1 天前
vscode部署stm32开发调试环境
ide·vscode·stm32
●VON2 天前
鸿蒙 PC Markdown 编辑器系统浏览器与图片查看器独立验收
华为·编辑器·harmonyos·鸿蒙
●VON2 天前
鸿蒙 PC Markdown 编辑器通信架构:受限 ArkTS-JavaScript Bridge
华为·架构·编辑器·harmonyos·鸿蒙