O'Reilly logo

Pro AngularJS by Adam Freeman

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

CHAPTER 20

image

Services for Ajax and Promises

In this chapter, I describe the built-in AngularJS services for making Ajax requests and representing asynchronous activities. These are important services, not just in their own right but because they provide the underpinnings for services that I describe in later chapters. Table 20-1 summarizes this chapter.

Table 20-1. Chapter Summary

Problem

Solution

Listing

Make Ajax requests.

Use the $http service.

1–3

Receive data from an Ajax request.

Register callback functions using the success, error, or then method on the object returned by the $http method.

4

Process non-JSON data.

Receive the ...

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