Can't bind to 'current' since it isn't a known property of 'round-progress'
See original GitHub issueHi I am trying to implement this in my app(Ionic 3) but it gives this error.
Error: Template parse errors: Can’t bind to ‘current’ since it isn’t a known property of ‘round-progress’.
- If ‘round-progress’ is an Angular component and it has ‘current’ input, then verify that it is part of this module.
- If ‘round-progress’ is a Web Component then add ‘CUSTOM_ELEMENTS_SCHEMA’ to the ‘@NgModule.schemas’ of this component
My code is home.ts -
import { NgModule } from '@angular/core'; import { RoundProgressModule, RoundProgressConfig } from 'angular-svg-round-progressbar'; @IonicPage() @Component({ selector: 'page-ownerhome', templateUrl: 'ownerhome.html', }) @NgModule({ imports: [RoundProgressModule] }) export class OwnerhomePage { current: any; max: any;
home.html -
<ion-header> <ion-navbar color="danger"> <ion-title>Home</ion-title> </ion-navbar> </ion-header> <ion-content padding> <ion-item> <round-progress [current]="current" [max]="max"></round-progress> </ion-item> </ion-content>
inside package.json -
"angular-svg-round-progressbar": "^1.2.1",
app.module.ts -
import { RoundProgressModule } from 'angular-svg-round-progressbar'; imports: [ BrowserModule, RoundProgressModule, IonicModule.forRoot(MyApp) ],
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (2 by maintainers)
Top GitHub Comments
You have to import the module in your page.module.ts too 😉
As tmdevde said, you need to import in home.module.ts, not home.ts