第一种使用script标签
<-- 注意:使用
第二种使用template标签
This is a component!
第三种 单文件组件
这种方法常用在vue单页应用中。详情看官网:
创建.vue后缀的文件,组件Hello.vue,放到components文件夹中{ { msg }}
app.vue
本文共 417 字,大约阅读时间需要 1 分钟。
<-- 注意:使用
This is a component!
这种方法常用在vue单页应用中。详情看官网:
创建.vue后缀的文件,组件Hello.vue,放到components文件夹中{ { msg }}
app.vue
转载于:https://www.cnblogs.com/huancheng/p/8883185.html