creativetimofficial / argon-design-system-angular

MIT License
248 stars 295 forks source link

ng build --prod is failing for Angular version of Argon Design System #7

Open jdcargile opened 4 years ago

jdcargile commented 4 years ago

This issue relates to the Angular version of Argon Design System. https://www.creative-tim.com/new-issue/argon-design-system-angular

Issue: Performing an ng build --prod dies with the following errors.

ERROR in src/app/sections/angular-section/angular-section.component.html:133:99 - error TS2551: Property 'model' does not exist on type 'AngularSectionComponent'. Did you mean 'model1'?

133           <input class="form-control datepicker" placeholder="Select date" name="dp" [(ngModel)]="model" ngbDatepicker #d="ngbDatepicker" (click)="d.toggle()" (focus)="focus2=true" (blur)="focus2=false" type="text" (select)="onDateSelection($event)" autocomplete="off"/>
                                                                                                      ~~~~~

  src/app/sections/angular-section/angular-section.component.ts:7:16
    7   templateUrl: './angular-section.component.html',
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component AngularSectionComponent.
src/app/sections/angular-section/angular-section.component.html:133:105 - error TS2551: Property 'model' does not exist on type 'AngularSectionComponent'. Did you mean 'model1'?

133           <input class="form-control datepicker" placeholder="Select date" name="dp" [(ngModel)]="model" ngbDatepicker #d="ngbDatepicker" (click)="d.toggle()" (focus)="focus2=true" (blur)="focus2=false" type="text" (select)="onDateSelection($event)" autocomplete="off"/>
                                                                                                            ~~~~~~

  src/app/sections/angular-section/angular-section.component.ts:7:16
    7   templateUrl: './angular-section.component.html',
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component AngularSectionComponent.
src/app/sections/angular-section/angular-section.component.html:133:226[0m - error TS2339: Property 'onDateSelection' does not exist on type 'AngularSectionComponent'.

133           <input class="form-control datepicker" placeholder="Select date" name="dp" [(ngModel)]="model" ngbDatepicker #d="ngbDatepicker" (click)="d.toggle()" (focus)="focus2=true" (blur)="focus2=false" type="text" (select)="onDateSelection($event)" autocomplete="off"/>
                                                                                                                                                                                                                                     ~~~~~~~~~~~~~~~~~~~~~~~

  src/app/sections/angular-section/angular-section.component.ts:7:16
    7   templateUrl: './angular-section.component.html',
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component AngularSectionComponent.
src/app/sections/angular-section/angular-section.component.html:146:178 - error TS2339: Property 'mama' does not exist on type 'AngularSectionComponent'.

146               <input class="form-control datepicker" placeholder="Select date" name="dp1" [(ngModel)]="model1" ngbDatepicker #d1="ngbDatepicker" (click)="d1.toggle()" (select)="mama($event)" type="text" [dayTemplate]="t" (dateSelect)="startDateChanged($event)" autocomplete="off" (focus)="focus3=true" (blur)="focus3=false"/>
                                                                                                                                                                                     ~~~~~~~~~~~~

  src/app/sections/angular-section/angular-section.component.ts:7:16
    7   templateUrl: './angular-section.component.html',
                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Error occurs in the template of component AngularSectionComponent.
merlo2802 commented 4 years ago

pudo sulucionar el error

rarestoma commented 4 years ago

Hi @jdcargile,

Thank you for working with our products.

Please replace the model with model1.

Also, please remove (select)="mama($event)" and (select)="onDateSelection($event)".

Please let me know if it works now.

Thank you, Rares

jdcargile commented 4 years ago

@rarestoma, I created a PR for the changes you referred to and tested ng build --prod locally. It's working now.