PageRenderTime 16ms CodeModel.GetById 11ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/node_modules/lodash/isNil.js

https://bitbucket.org/coleman333/smartsite
JavaScript | 25 lines | 4 code | 1 blank | 20 comment | 1 complexity | 0e4b4f42716b39241fae5cbced070881 MD5 | raw file
 1/**
 2 * Checks if `value` is `null` or `undefined`.
 3 *
 4 * @static
 5 * @memberOf _
 6 * @since 4.0.0
 7 * @category Lang
 8 * @param {*} value The value to check.
 9 * @returns {boolean} Returns `true` if `value` is nullish, else `false`.
10 * @example
11 *
12 * _.isNil(null);
13 * // => true
14 *
15 * _.isNil(void 0);
16 * // => true
17 *
18 * _.isNil(NaN);
19 * // => false
20 */
21function isNil(value) {
22  return value == null;
23}
24
25module.exports = isNil;