您当前的位置: 首页 > 

73Vue - 内联模版

杨林伟 发布时间:2019-07-29 11:50:09 ,浏览量:3

如果子组件有 inline-template 特性,组件将把它的内容当作它的模板,而不是把它当作分发内容。这让模板更灵活。


  

These are compiled as the component's own template.

Not parent's transclusion content.

但是 inline-template 让模板的作用域难以理解。最佳实践是使用 template 选项在组件内定义模板或者在.vue文件中使用 template元素。

关注
打赏
1688896170
查看更多评论

杨林伟

暂无认证

  • 3浏览

    0关注

    3183博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文
立即登录/注册

微信扫码登录

0.0764s