I have some data which can be string or array. So if it is a string, I want to display it, and if it is an array, I want to display length of it.
Trying to check data type of:
<div class="properties">{{typeof(row.contact)=="object" ? 1 : 2}}</div>//with 1 and 2 its more simplify.
But in both cases it will display 2
. Why is it so and how can I fixed it?
P.S.
{{angular.isArray(value)? 1 : 2}}//result the same