个人在敲js代码的时候会经常碰到写完一行,鼠标光标还在小括号内,然后还要按end键加分号(本人习惯写分号,就算有eslint Q-Q),然后再回车换行,感觉这样很麻烦,研究了许久得出了快捷键的设置方法:
1.先安装插件multi-command
2.文件-》首选项-》键盘快捷方式-》右上角打开键盘快捷方式(小图标)
3.在kedbindings.json的[]中输入
{ "key": "ctrl+;", "command": "extension.multiCommand.execute", "args": { "sequence": [ { "command": "cursorEnd" }, { "command": "type", "args": { "text": ";" } }, { "command": "editor.action.insertLineAfter" } ] }, "when": "editorTextFocus" }
4.ctrl+;即可使用
标签:加分,ctrl,vscode,args,换行,command,快捷方式 From: https://www.cnblogs.com/idontcare/p/17958336