dschnelldavis / angular2-json-schema-form

Angular 2 JSON Schema Form builder
MIT License
285 stars 177 forks source link

Cant build in prod #109

Closed rokytskyi closed 6 years ago

rokytskyi commented 7 years ago

When i try to build project in prod, i catch error

ERROR in Error: Template parse errors: Can't bind to 'mdDatepickerToggle' since it isn't a known property of 'button'. (" !formControl?.dirty" align="end">{{options?.placeholder}}</md-hint> <button mdSuffix [ERROR ->][mdDatepickerToggle]="picker"></button> </md-input-container> <md-datepicker #picker "): ng:///../node_modules/angular2-json-schema-form/angular2-json-schema-form.d.ts.ɵbl.html@25:23

dschnelldavis commented 6 years ago

This was a problem with the Material Design library. They changed all their prefixes from "md..." to "mat..." and recently stopped supporting the old syntax. So "mdDatepickerToggle" is now "matDatepickerToggle".

The latest version of angular2-json-schema-form (currently 0.5.0-alpha.14) has completely switched to the new prefixes and should no longer cause any errors like this.