O'Reilly logo

Mastering Web Application Development with AngularJS by Pawel Kozlowski, Peter Bacon Darwin

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

AngularJS crash course

Now that we know where to find the library sources and their accompanying documentation, we can start writing code to actually see AngularJS in action. This section of the book lays the foundation for the subsequent chapters by covering AngularJS templates, modularity, and dependency injection. Those are the basic building blocks of any AngularJS web application.

Hello World – the AngularJS example

Let's have a look at the typical "Hello, World!" example written in AngularJS to get the first impression of the framework and the syntax it employs.

<html>
<head>
    <script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.0.7/angular.js"></script>
</head>
<body ng-app ng-init="name = 'World'"> <h1>Hello, {{name}}!</h1> </body> ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required