data binding in angular

Solutions on MaxInterview for data binding in angular by the best coders in the world

showing results for - "data binding in angular"
Facundo
05 Nov 2020
1<input [disabled]="condition ? true : false">
2<input [attr.disabled]="condition ? 'disabled' : null">
Paola
09 Nov 2019
1    // component.ts
2
3    @Component({
4      templateUrl: 'component.html',
5      selector: 'app-component',
6    })
7    export class Component {
8      name = 'Peter';
9
10      updateName() {
11        this.name = 'John';
12      }
13    }
14        // component.html
15
16    <p>My name is {{name}}</p>
17    <button (click)="updateName()">Update button</button>
similar questions
queries leading to this page
data binding in angular