Disable Button in Angular 2
Solution 1:
Change ng-disabled="!contractTypeValid"
to [disabled]="!contractTypeValid"
Solution 2:
I tried use [disabled]="!editmode"
but it not work in my case.
This is my solution [disabled]="!editmode ? 'disabled': null"
, I share for whom concern.
<button [disabled]="!editmode ? 'disabled': null"
(click)='loadChart()'>
<div class="btn-primary">Load Chart</div>
</button>
Stackbliz https://stackblitz.com/edit/angular-af55ep