The ability to reply to discussions is limited to PRO members. Want to join in the discussion? Click here to subscribe now.

Value Providers

Value Providers

3:00
Dependecies aren’t always objects created by classes or factory functions. Sometimes, all we really want is inject a simple value, which can be a primitive, or maybe just a configuration object. For these cases, we can use value providers and in this lesson we’ll discuss, how they are created.
Watch this lesson now
Avatar
egghead.io

Dependecies aren’t always objects created by classes or factory functions. Sometimes, all we really want is inject a simple value, which can be a primitive, or maybe just a configuration object. For these cases, we can use value providers and in this lesson we’ll discuss, how they are created.

Avatar
sooey

It may also be useful to know that in order for Typescript to render the necessary meta data, so that the Inject() attribute isn't needed, that the tsconfig needs to include: '"emitDecoratorMetadata": true. I hope this helps somebody. Also, thanks for the tutorial... great job!

HEY, QUICK QUESTION!
Joel's Head
Why are we asking?