Book Image

AngularJS by Example

By : Chandermani
Book Image

AngularJS by Example

By: Chandermani

Overview of this book

<p>AngularJS makes web JavaScript web development less painful and more organized – it’s unsurprising that today it’s one of the most popular tools in web development.</p> <p>AngularJS by Example helps you get started with this essential web development framework quickly and easily, guiding you through AngularJS by showing you how to create your own real-world applications. By adopting this approach, you can bridge the gap between learning and doing immediately, as you follow the examples to learn the impressive features of Angular and experience a radically simple–and powerful–approach to web development.</p> <p>You’ll begin by creating a simple Guess the Number game, which will help you get to grips with the core components of Angular, including its MVC architecture, and learn how each part interacts with one another. This will give you a solid foundation of knowledge from which you can begin to build more complex applications, such as a 7 minute workout app and an extended personal trainer app. By creating these applications yourself, you will find out how AngularJS manages client-server interactions and how to effectively utilize directives to develop applications further. You’ll also find information on testing your app with tools such as Jasmine, as well as tips and tricks for some of the most common challenges of developing with AngularJS.</p> <p>AngularJS by Example is a unique web development book that will help you get to grips with AngularJS and explore a powerful solution for developing single page applications.</p>
Table of Contents (15 chapters)
AngularJS by Example
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Summary


The journey has started and we have reached the first milestone. Despite this chapter being entitled Getting Started, we have covered a lot of concepts that will be necessary for us to know so as to understand the bigger picture. Our learning was derived from our Guess the Number! app that we built and dissected throughout the chapter.

We learned about the MVC triad starting from the model and designed the model for our Guess the Number! app. We learned how to expose the model over the scope object and how the model drives the view in AngularJS.

We explored the view part of MVC and designed our view. We learned more about AngularJS binding and understood the live nature of these bindings. We explored the new AngularJS view constructs: interpolations and directives, and understood the role expressions play in the framework.

The last MVC element was the controller. We learned about the AngularJS controller and how it works in close sync with the view to provide the necessary behavior. One important consideration that came out of this discussion was that the controller does not directly refer the view or manipulate it.

Once we had a good understanding of AngularJS and the MVC component, we focused our efforts on learning about scopes. We learned how the scope is the glue between the view and the model. We saw scope objects defined inside our game and how changes in the model and view are synced by the framework.

To round things off, we learned about a very important process in AngularJS: app bootstrapping. By exploring the bootstrap process, we were able to connect the dots and answer a number of questions that related to scopes, binding, and app initialization itself.

The groundwork has been done and now we are ready for some serious app development on the AngularJS framework. In the next chapter, we will start working on a more complex exercise and expose ourselves to a number of new AngularJS constructs.