快速在vue3.0 中创建vue文件(快捷键)
作者:互联网
VScode》文件》首选项》用户片段》vue.json(Vue)
vue.json配置:
{
"Print to console":{
"prefix": "vuec",
"body": [
"<template>",
" <div>",
" </div>",
"</template>",
"",
"<script>",
"import { defineComponent } from 'vue'",
"export default defineComponent ({",
" name:'',",
" components:{},",
" props:{},",
" setup(props, ctx){",
" return {",
" }",
" },",
"})",
"</script>",
"",
"<style scoped>",
"</style>"
],
"description": "A vue file template"
}
}
配置完成之后,创建一个.vue文件,输入vuec 快速创建
标签:vue,vuec,创建,快捷键,json,vue3.0,props,defineComponent 来源: https://blog.csdn.net/weixin_39418338/article/details/120428155