In this example we have a required URL field in the ng-form. If you leave this field empty or enter invalid url the button gets disable.
ng-form