The Wayback Machine - https://web.archive.org/web/20201220220232/https://github.com/lodash/lodash/blob/master/ceil.js
Skip to content
Permalink
master
Go to file
 
 
Cannot retrieve contributors at this time
24 lines (22 sloc) 552 Bytes
import createRound from './.internal/createRound.js'
/**
* Computes `number` rounded up to `precision`. (Round up: the smallest integer greater than or equal to a given number.)
*
* @since 3.10.0
* @category Math
* @param {number} number The number to round up.
* @param {number} [precision=0] The precision to round up to.
* @returns {number} Returns the rounded up number.
* @example
*
* ceil(4.006)
* // => 5
*
* ceil(6.004, 2)
* // => 6.01
*
* ceil(6040, -2)
* // => 6100
*/
const ceil = createRound('ceil')
export default ceil
You can’t perform that action at this time.