AngularJS ¶
- angularjs.org 링크
<div ng-app=""> {{todos}} <h3 ng-init="todos=[]"> Topic </h3> <ul> <li ng-repeat="todo in todos" class="done-{{todo.done}}"> <input type="checkbox" ng-model="todo.done"/> {{todo.text}} <button ng-click="todos.splice($index,1)">x</button> </li> </ul> <form ng-submit="test && todos.push({text:test,done:false});test=''"> <input type="text" ng-model="test"/> <button>Input</button> </form> </div>