您的位置:首页 > Web前端 > AngularJS

AngularJS数据双向绑定

2016-12-08 12:02 337 查看
<body ng-app>
<div ng-controller="myCtrl">
<input ng-model="abc" type="text">
<h1>{{abc}}</h1>
<input ng-model="bind" type="text">
<h1>{{bind}}</h1>
</div>
<script>
function myCtrl($scope) {
$scope.abc = '';
$scope.bind = '';
}
</script>
</body>


  
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: