Join Justin Schwartzenberger for an in-depth discussion in this video How Angular does dependency injection, part of Angular 2 Essential Training (2016).
- View Offline
- Exercise Files
- Code Practice
- [Voiceover] Angular has Dependency Injection support…baked into the framework.…It's a big part of what allows you to create…this components directives and more…in a modular fashion.…Where they don't have to have knowledge…of one another to coexist.…With Dependency Injection…the framework is handling…creating instinctive of things…and injecting them to places where they are needed.…In Angular this is handled in two steps.…The first is Service Registration,…in which you provide Angular…with a list of things you wanted to know about,…that can be Injected.…
The second is a retrieval of those things.…Which can be done by constructor injection…either by leveraging TypeScript type annotations,…or by using the Angular Inject Decorater.…Angular also provides access to the injector itself,…for cases where you want to locate a service specifically.…But this is typically not needed.…The majority of application architecting,…can be accomplished by…leveraging constructor injection.…So step one is to tell Angular,…Hey! I have this class or this value,…
- What is Angular?
- Setting up an Angular template
- Creating a component
- Displaying data
- Working with events
- Using two-way data binding
- Creating a subcomponent
- Using the built-in HTTP module
- Using the built-in router module
Skill Level Intermediate
AngularJS and WordPress: Building a Single-Page Applicationwith Roy Sivan31m 52s Intermediate
Building a Mobile App with AngularJS 1 and Ionicwith Ray Villalobos3h 31m Intermediate
1. Architecture Overview
3. Directives and Pipes
5. Dependency Injection and Services
Next steps1m 20s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.