Going Postal with Angular in Promises
summary
Explains why promises are more than callback sugar and shows concrete Angular 1.2 uses: $http/$timeout return promises, $resource exposes a .promise property, deferred = postman as the only resolver, and resolve in routes to block route change until data is ready. Demonstrates UI Bootstrap modal.result chaining, service-wrapped lazy promises for global access, HTTP interceptors that pause requests by returning unresolved promises, and notes native Promises arriving in Chrome 32.
AI-written summary · about
chapters (12)
- 0:00Introduction and context
- 1:44Problems with callbacks
- 4:14Promises as problem solvers
- 6:23Declarative async with promises
- 8:51Promises and deferred explained
- 10:59User uncertainty and promises
- 11:42Promises in Angular basics
- 14:11Route resolution in Angular
- 16:18Third-party promise usage
- 17:22Referencing unresolved promises
- 18:26HTTP interceptors with promises
- 19:29Native promises and future
