I am encountering an issue with large numbers retrieved from a web service and displayed in an <input type="number">
field. Everything works fine until Angular converts the values to scientific notation. The value is displayed correctly initially, but if the user tries to modify it, the value gets silently deleted.
Below is an example code snippet:
<div ng-app="testApp" ng-controller="testController">
<input ng-model="value1" type="number" />{{ value1 }}
</div>
var app = angular.module("testApp", []);
app.controller('testController', function ($scope) {
$scope.value = 1e+100;
});
http://jsfiddle.net/SJVH7/10/ (try modifying the first input box to 1e+101)
What is the best way to handle such large numbers in this scenario?