使用VsCode写ts版的vue时,设置快捷编辑

1.

2.

输入 vue 点击第一项

3.

vue.json中输入代码

{
"Vue Template":{
"prefix":"vueTemplate",
"body":[
"<template>\n\t<div>\n\n\t</div>\n</template>\n\n",
"<script lang=\"ts\">\nimport{Component,Vue}from 'vue-property-decorator';\n\n@Component\nexport default class ${1:ClassName} extends Vue{\n$0\n}\n</script>\n\n",
"<style lang=\"scss\" scope>\n\n</style>"
],
"description":"生成vue文件"
}
}

 

4.

在vue文件中输入

vtem就可以提示快捷语法

 

posted @ 2020-04-06 15:28  是你的天天呢  阅读(1630)  评论(0)    收藏  举报