Home >Web Front-end >JS Tutorial >Use angular to write a hello world_AngularJS

Use angular to write a hello world_AngularJS

WBOY
WBOYOriginal
2016-05-16 16:18:241255browse

angularjs follows the MVC model, as usual, let’s have a hello world

Copy code The code is as follows:








                                                                                                       




Contents in controllers.js

Copy code The code is as follows:
function HelloController($scope) {
$scope.greeting = { text: "Hello"};
}

MVC feels very good to write~~

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn