vue笔记-----component粒子2
来源:互联网 发布:法兰绒格子衬衫 知乎 编辑:程序博客网 时间:2024/06/05 15:25
1.html
<div id="app">
<ol>
<todo-item v-for="item in groceryList" v-bind:todo="item"></todo-item>
</ol>
</div>
2.script
Vue.component('todo-item',{
props:[todo],
template:'<li>{{todo.text}}</li>'
})
var app = new Vue({
el:'#app',
data:{
groceryList:[
{text:'Vegetables'},
{text:cheese},
{text:Whatever else humans are suppoesd to eat}
]
}
})
0 0
- vue笔记-----component粒子2
- vue笔记-----component粒子1
- vue-component
- VUE component
- vue component 组件使用
- vue component组件小结
- Vue-component全局注册
- vue component组件
- vue 组件(Component)
- Vue中组件(component)
- Vue.component使用注意事项
- vue组件 component
- 粒子笔记
- Vue.extend和Vue.component的区别
- vue笔记。Demo 2
- vue学习笔记2
- Vue component-based application structure
- 如何封装一个vue component
- 沪江 iOS 技术沙龙随想
- maven 亲测可用国内镜像 阿里云
- Selenium + java
- git add -A , git add . ,git add -u三者的区别
- 放大镜效果
- vue笔记-----component粒子2
- nodejs与npm升级到最新版本的方法
- android studio 2.3 NDK
- [LeedCode] Single Number II
- MySql之约束
- 树形结构
- Codeforces Round #403 D. Innokenty and a Football League(思维+模拟)
- DrawableLayout实现仿QQ侧滑菜单
- Unicode和Utf-8