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

Combine HostBinding with Services in Angular 2 Directives

Combine HostBinding with Services in Angular 2 Directives

3:08
You can change behaviors of element and `@Component` properties based on services using `@HostBinding` in `@Directives`. This allows you to build `@Directive`s which rely on services to change behavior without the `@Component` ever needing to know that the Service even exists.
Watch this lesson now
Avatar
egghead.io

You can change behaviors of element and @Component properties based on services using @HostBinding in @Directives. This allows you to build @Directives which rely on services to change behavior without the @Component ever needing to know that the Service even exists.

Avatar
ofir

is the Hostlistener events remove OnDestroy ?

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