1234567

Develop smaller, lighter web apps that are simple to create and easy to test, extend, and maintain as they grow. This hands-on guide introduces you to AngularJS, the open source JavaScript framework that uses Model–view–controller (MVC) architecture, data binding, client-side templates, and dependency injection to create a much-needed structure for building web apps.

Guided by two engineers who worked on AngularJS at Google, you’ll walk through the framework’s key features, and then build a working AngularJS app—from layout to testing, compiling, and debugging. If you have JavaScript experience, you’ll learn how AngularJS helps reduce the complexity of your web app.

  • Dive deep into Angular’s building blocks and learn how they work together
  • Gain maximum flexibility by separating logic, data, and presentation responsibilities with MVC
  • Assemble your full app in the browser, using client-side templates
  • Use AngularJS directives to extend HTML with declarative syntax
  • Communicate with the server and implement simple caching with the $http service
  • Use dependency injection to improve refactoring, testability, and multiple environment design
  • Get code samples for common problems you face in most web apps

Brad Green

Brad Green works at Google as an engineering manager. In addition to the AngularJS project, Brad also directs Accessibility, and Support Engineering. Prior to Google, Brad worked on the early mobile web at AvantGo, founded and sold startups, and spent a few hard years toiling as a caterer. Brad's first job out of school was as lackey to Steve Jobs at NeXT Computer writing demo software and designing his slide presentations. Brad lives in Mountain View, CA with his wife and two children.

Shyam Seshadri

Shyam Seshadri is the owner / CEO of Fundoo Solutions (http://www.befundoo.com), where he splits his time between working on innovative and exciting new products for the Indian markets, and consulting about and running workshops on AngularJS. Prior to Fundoo Solutions, Shyam completed his MBA from the prestigious Indian School of Business in Hyderabad. Shyam's first job out of college was with Google, where he worked on multiple projects, including Google Feedback (AngularJS's first customer!), and various internal tools and projects. Shyam currently operates from his office in Navi Mumbai, India.

  1. Chapter 1 Introduction to AngularJS

    1. Concepts

    2. An Example: Shopping Cart

    3. Up Next

  2. Chapter 2 Anatomy of an AngularJS Application

    1. Invoking Angular

    2. Model View Controller

    3. Templates and Data Binding

    4. Organizing Dependencies with Modules

    5. Formatting Data with Filters

    6. Changing Views with Routes and $location

    7. Talking to Servers

    8. Changing the DOM with Directives

    9. Validating User Input

    10. Moving On

  3. Chapter 3 Developing in AngularJS

    1. Project Organization

    2. Tools

    3. Running Your Application

    4. Testing with AngularJS

    5. Unit Tests

    6. End-to-End/Integration Tests

    7. Compilation

    8. Other Awesome Tools

    9. Yeoman: Optimizing Your Workflow

    10. Integrating AngularJS with RequireJS

  4. Chapter 4 Analyzing an AngularJS App

    1. The Application

    2. Relationship Between Model, Controller, and Template

    3. The Model

    4. Controllers, Directives, and Services, Oh My!

    5. The Templates

    6. The Tests

  5. Chapter 5 Communicating with Servers

    1. Communicating Over $http

    2. Unit Testing

    3. Working with RESTful Resources

    4. The $q and the Promise

    5. Response Interception

    6. Security Considerations

  6. Chapter 6 Directives

    1. Directives and HTML Validation

    2. API Overview

    3. Moving On

  7. Chapter 7 Other Concerns

    1. $location

    2. AngularJS Module Methods

    3. Communicating Between Scopes with $on, $emit, and $broadcast

    4. Cookies

    5. Internationalization and Localization

    6. Sanitizing HTML & the Sanitize Module

  8. Chapter 8 Cheatsheet and Recipes

    1. Wrapping a jQuery Datepicker

    2. The Teams List App: Filtering and Controller Communication

    3. File Upload in AngularJS

    4. Using Socket.IO

    5. A Simple Pagination Service

    6. Working with Servers and Login

    7. Conclusion

  9. Index

  10. Colophon