Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

angularjs round to 2 decimal places input


<input type="number" name="myDecimal" placeholder="Decimal" ng-model="myDecimal | number : 2" ng-pattern="/^[0-9]+(.[0-9]{1,2})?$/" step="0.01" />
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #angularjs #decimal #places #input
ADD COMMENT
Topic
Name
5+2 =