-
Notifications
You must be signed in to change notification settings - Fork 14
/
test.html
30 lines (30 loc) · 869 Bytes
/
test.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<!DOCTYPE html>
<html ng-app="app">
<head>
<style>
body{background-color:#fff;}
form{width:600px;margin:15% auto;}
</style>
<link rel="stylesheet" href="ngTagEditor.css" type="text/css"/>
<script type="text/javascript" src="http://cdn.jsdelivr.net/angularjs/1.2.17/angular.min.js"></script>
<script type="text/javascript" src="ngTagEditor.js"></script>
<script type="text/javascript">
angular.module('app', ['ngTagEditor'])
.controller('RandomController', function($scope){
$scope.tags = [
{name: 'See'},
{name: 'how'},
{name: 'amazing'},
{name: 'is'},
{name: 'AngularJS'}
];
});
</script>
</head>
<body>
<form ng-controller="RandomController">
<tag-editor ng-model="tags" output="name" fetch="suggestions.json"></tag-editor>
<span class="log">{{tags}}</span>
</form>
</body>
</html>