-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Closed
Description
Bug
Property 'underlineRef' does not exist on type 'MdInputDirective'
However, underlineRef property exists if we log this MdInputDirective:
Expected behavior
@ViewChild('input') input: MdInputDirective;
ngOnInit(): void {
this.input.underlineRef.nativeElement.className = null; // Removes the input underline
}
What is the current behavior?
Compilation error
What are the steps to reproduce?
Link of a discussion on the issue:
https://stackoverflow.com/questions/45556972/how-to-hide-delete-underline-input-angular-material
Is there anything else we should know?
Workaround
@ViewChild('input') input: MdInputDirective;
ngOnInit(): void {
this.input['underlineRef'].nativeElement.className = null; // Remove the input underline
}
Metadata
Metadata
Assignees
Labels
No labels