why does angularjs blank out the input field when ng-maxlength is exceeded on initialization? -


If I have an input text field whose value is more than NG-MAXLead over form load (input still $ is real , Not $ dirty), the input field is empty from misery, while the ng-model still has data.

I want to present the same data to the input which is the model, why is it showing me a blank?

Is this a bug? Is this intention behavior?

This is because after the greater than the NG-max lamp standard, angular believes the JS input is undefined . You can use HTML Maximal Attribute with NG-Maxlemth. The HML Exclamation will limit the input value to that limit and the NG-model will only store the input value for a limited length. And you can use ng-maximalband to show an error in crossing the border.


Comments

Popular posts from this blog

eclipse plugin - Run java code error: Workspace is closed -

ios - How do I use CFArrayRef in Swift? -

scala - Play Framework - how to bind form to a session field -