On Github twilson63 / working-with-angularjs
Created by Tom Wilson / @twilson63
<div ng-app> <h1>{{title}}</h1> <input type="text" ng-model="title"> </div>Live Demo
function MainCtrl($scope, $http) { $http.get('http://jsbin.com/abaqip') .success(function(data) { $scope.repos = data; }); }
<ul> <li ng-repeat="repo in repos" > {{name}} </li> </ul>
<body ng-app="MyApp"> <ng-view></ng-view> </body>
angular.module('MyApp', []) .config(function($routeProvider) { $routeProvider .when('/', { template: 'main.html', controller: 'MainCtrl'}) .when('/page2', { template: 'page2.html', controller: 'Page2Ctrl'}) })
<input type="text" ng-model="search"> <ul> <li ng-repeat="repo in repos | filter:search | orderBy: 'name'" > {{name}} </li> </ul>Live Demo
<blink>Like its 1999</blink>
angular.module('MyApp', []) .directive('blink', function() { return { template: '<marquee scrollamount="100%">Blink!</marquee>' } });Live Demo