I am using angular js. How can i call a function if the length of the input text id greater than 5.
<input class="form-control" style="width:230px" ngmodel="Lookupemployer" ng-if={{ }} />
I want to call the below function
$scope.get = function()
{
}
if the length of the Lookupemployer is greater than 5.
I tried like this
ng-if={{ Lookupemployer.length >5 ? get() : ""}}
but did not work. Can anyone help me
Thanks,
Lookupemployer? is it a string, an object, an array, a function? it's not really clear here, either from the code or from the name. The name makes me think function, but the use makes me think string.ng-ifis doing.ng-ifdetermines if to render the element based on the condition