Angular2 RC6 upgrade

前端 未结 3 821
轮回少年
轮回少年 2021-01-12 16:13

after updating my project to RC6 following errors occurs:

Error: Typescript found the following errors:
  app.component.ts (12, 3): Argument of          


        
3条回答
  •  不要未来只要你来
    2021-01-12 16:43

    For Angular 2 final version 2.0.0.0

    the pipe should be declared in declaration section of app.module.ts file

    import {KeysPipe} from './keys.pipe';
    
    @NgModule({
      imports:      [ BrowserModule, FormsModule, HttpModule ],
      declarations: [ AppComponent, LoginComponent,ArticleComponent,**KeysPipe** ],
      bootstrap:    [ AppComponent, LoginComponent,ArticleComponent ],
    
    
    })
    

    just observe keyspipe implementation in above code snippets.

提交回复
热议问题