Reputation: 587
I want all inputs to be required and enable the button just if the user fill all the inputs. but now when the user fill just the first one the button enabled.
here is the Plunker
Thanks a lot.
Upvotes: 1
Views: 363
Reputation: 17879
You need to have unique names for each input.
change
<input type="text" name="options" ngModel required>
to:
<input type="text" [name]="element" ngModel required>
Upvotes: 1