Skip to content

Instantly share code, notes, and snippets.

@karthikchintala1
Created July 1, 2017 06:04
Show Gist options
  • Save karthikchintala1/7f3d82009fe0721db4308ff792e795b9 to your computer and use it in GitHub Desktop.
Save karthikchintala1/7f3d82009fe0721db4308ff792e795b9 to your computer and use it in GitHub Desktop.
Adding directive to app.module.ts
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { AppComponent } from './app.component';
import { ColorDirective } from './color.directive'; //import the color directive
@NgModule({
declarations: [
AppComponent,
ColorDirective //added here
],
imports: [
BrowserModule
],
bootstrap: [AppComponent]
})
export class AppModule { }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment