Skip to content

Can't bind to 'floatPlaceholder' since it isn't a known property of 'mat-form-field'. #286

Open
@neil-coutinho

Description

@neil-coutinho

Issue type

I'm submitting a (check one):
[x] Bug report
[ ] Feature request
[ ] Regression (something that used to work, but stopped working in a newer version)
[ ] Support request
[ ] Documentation issue or request

Prerequisites

Before posting, make sure you do the following (check all):
[x] Confirm you are using the latest versions of all necessary packages (or if not, explain why not)
[x] Search GitHub for a similar issue or PR
[x] If submitting a Support request, also search Stack Overflow for similar issues
Note: Please cross-post GitHub support requests to Stack Overflow, and include a link in your GitHub issue to your Stack Overflow question. We do currently respond to support requests on GitHub, but we eventually expect to stop, and will then refer all support questions exclusively to Stack Overflow.

Current behavior

After upgrading to Angular and Angular Material to 6.0.2, You get the following error on production mode i.e. ng serve --prod

ERROR in: Can't bind to 'floatPlaceholder' since it isn't a known property of 'mat-form-field'.

If 'mat-form-field' is an Angular component and it has 'floatPlaceholder' input, then verify that it is part of this module.
If 'mat-form-field' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component. ("
<mat-form-field
[class]="options?.htmlClass || ''"
[ERROR ->][floatPlaceholder]="options?.floatPlaceholder || (options?.notitle ? 'never' : 'auto')"
[style.")

Expected behavior

Should run w/o any erros

IMPORTANT: How can we reproduce your problem?

Upgrade your Angular version to 6

Upgrade all Angular packages

Environment

OS name & version: macOS Sierra 10.12.6
Browser name & version: Chrome version 66.0.3359.139 (Official Build) (64-bit)
Angular version: 6.0.2
Angular JSON Schema Form version(s): ^0.7.0-alpha.1
Other relevant software or packages:
Angular CLI: 6.0.3
Node: 8.9.4
OS: darwin x64
Angular: 6.0.2
... animations, cdk, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router

angular-devkit/architect: 0.6.3
angular-devkit/build-angular: 0.6.3
angular-devkit/build-optimizer: 0.6.3
angular-devkit/core: 0.6.3
angular-devkit/build-optimizer: 0.6.3
angular-devkit/schematics: 0.6.3
angular/cli: 6.0.3
angular/flex-layout: 2.0.0-beta.12
angular/material: 6.1.0

Any other relevant information

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions