Вы находитесь на странице: 1из 1

benefits of angularJS

------------------------
dependency injection
two way data-binding
testing
MVC
directives, filters (controlling behaviour of DOM)
routes

ng-app (attribute) -- directive


angular expr/binding expr {{10+20}}
controllers,services,directives,filters etc
var myApp = angular.module("mymodule",[])

var mycontroller = function($scope){


$scope.message="angular js";
}
attach model to scope

//register controller with module


myApp.controller("myController", myController);

data you attach to scope.....

image to display we have directive (instead of hardcode earlier in javascript)

Вам также может понравиться