I want to write a filter in angularjs that separates thousands by whitespaces for example
(1000 -> 1 000)
and if (1000.555 -> 1 000.555)
.
Now I am trying to do the next but it seems does not work:
app.filter('split', function () {
return function (number, number2) {
if (number/3==1){
return number;
}else{
return number.split(".")+"."+ number2.split('.')
}
}
});
and for my input I put the next <input type="text" {{someExpression|split}} >