Property 'checked' does not exist on type 'HTMLElement' angular 4
Use this:
const ele = document.getElementById("idOfElement") as HTMLInputElement;
ele.checked = false;
In your HTML
<input #abcde type="checkbox" (change)="func()" />
In your component
import { Component, ViewChild, ElementRef } from '@angular/core';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
@ViewChild('abcde') abcde: ElementRef;
func() {
this.abcde.nativeElement.checked
}
}