ceil.js
Ceils the given value to the specified number of decimal places.
Install
npm install ceil
API
ceil(value)
Returns the smallest integer greater than or equal to value
.
var ceil = require('ceil');
ceil(.95);
ceil(4);
ceil(7.004);
ceil(value, scale)
Returns the smallest integer greater than or equal to value
to scale
(+/-) number of decimal places.
var ceil = require('ceil');
ceil(55.51, -1);
ceil(51, 1);
ceil(-55.59, -1);
ceil(-59, 1);
ceil(12489.9482, 5);
ceil(12489.9482, 4);
ceil(12489.9482, 3);
ceil(12489.9482, 2);
ceil(12489.9482, 1);
ceil(12489.9482, 0);