Angular Ngmodel

Every App need a Root NgModel;
if you want to add feature NgModle,you can init it as AppModule.Then you import it into AppModule.
Example:
@NgModule({
providers: [
ActiveTitleService
],
imports: [
BrowserModule,
UserModule // Feature Module
],
declarations: [
AppComponent,
TitleComponent,
HighlightDirective
],
bootstrap: [ AppComponent ]
})

Leave a Reply

Your email address will not be published. Required fields are marked *