UNPKG

bingo-functional-js

Version:

A port of the PHP bingo-functional library

15 lines (12 loc) 238 B
/** * isNumber function * isNumber :: a -> Bool * @param {*} val * @returns {boolean} * @example * * isNumber(9) * // => true */ const isNumber = (val) => typeof val === 'number' && !Number.isNaN(val) module.exports = isNumber