Answer the question
In order to leave comments, you need to log in
Angular 7 how to add input checkbox class?
Hello, I have something like this structure:
<div class="switch" [ngClass]=""></div>
<input type="checkbox" [checked]="func">
Answer the question
In order to leave comments, you need to log in
<div [class.checked]="myCheckbox.checked">bla bla</div>
<input #myCheckbox type="checkbox" (change)="onChange()">
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question