hello angular JS
hello angular JS
<html ng-app="myApp"> <head> <title> hello angular</title> <script src="Scripts/angular.js"></script> </head> <body> <div ng-controller="testCtrl"> <ul> <li ng-repeat="phone in phones"> {{phone.name}} <p>{{phone.snippet}}</p> </li> </ul> </div> <script> var myApp = angular.module('myApp', []); myApp.controller('testCtrl', ['$scope', function ($scope) { $scope.phones = [ { "name": "Nexus S", "snippet": "Fast just got faster with Nexus S." }, { "name": "Motorola XOOM™ with Wi-Fi", "snippet": "The Next, Next Generation tablet." }, { "name": "MOTOROLA XOOM™", "snippet": "The Next, Next Generation tablet." } ]; }]); </script> </body> </html>
怎么样快速入门AngularJS?
http://www.ngnice.com/posts/205af1ea1e13d2
fffffffffffffffff
test red font.