angularjs

$index只在ng-repeat中起作用,它的作用是获取当前标签的索引值。除了$index外还有$first,$middle,$last,$even,$odd

ng-class = 为true时添加class为false时为空或添加别的样式

ng-show = 为true时显示你想要的东西

ng-bind = 绑定你的model到html

$apply()让页面知道检查数据有没有变化

猜你喜欢

转载自gaofan0528.iteye.com/blog/2398262