112 lines
3.0 KiB
JavaScript
112 lines
3.0 KiB
JavaScript
(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.returnExports = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){
|
|
/**
|
|
* @file Checks if `value` is `null` or `undefined`.
|
|
* @version 1.4.1
|
|
* @author Xotic750 <Xotic750@gmail.com>
|
|
* @copyright Xotic750
|
|
* @license {@link <https://opensource.org/licenses/MIT> MIT}
|
|
* @module is-nil-x
|
|
*/
|
|
|
|
'use strict';
|
|
|
|
var isUndefined = _dereq_('validate.io-undefined');
|
|
var isNull = _dereq_('lodash.isnull');
|
|
|
|
/**
|
|
* Checks if `value` is `null` or `undefined`.
|
|
*
|
|
* @param {*} value - The value to check.
|
|
* @returns {boolean} Returns `true` if `value` is nullish, else `false`.
|
|
* @example
|
|
* var isNil = require('is-nil-x');
|
|
*
|
|
* isNil(null); // => true
|
|
* isNil(void 0); // => true
|
|
* isNil(NaN); // => false
|
|
*/
|
|
module.exports = function isNil(value) {
|
|
return isNull(value) || isUndefined(value);
|
|
};
|
|
|
|
},{"lodash.isnull":2,"validate.io-undefined":3}],2:[function(_dereq_,module,exports){
|
|
/**
|
|
* lodash 3.0.0 (Custom Build) <https://lodash.com/>
|
|
* Build: `lodash modern modularize exports="npm" -o ./`
|
|
* Copyright 2012-2015 The Dojo Foundation <http://dojofoundation.org/>
|
|
* Based on Underscore.js 1.7.0 <http://underscorejs.org/LICENSE>
|
|
* Copyright 2009-2015 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
* Available under MIT license <https://lodash.com/license>
|
|
*/
|
|
|
|
/**
|
|
* Checks if `value` is `null`.
|
|
*
|
|
* @static
|
|
* @memberOf _
|
|
* @category Lang
|
|
* @param {*} value The value to check.
|
|
* @returns {boolean} Returns `true` if `value` is `null`, else `false`.
|
|
* @example
|
|
*
|
|
* _.isNull(null);
|
|
* // => true
|
|
*
|
|
* _.isNull(void 0);
|
|
* // => false
|
|
*/
|
|
function isNull(value) {
|
|
return value === null;
|
|
}
|
|
|
|
module.exports = isNull;
|
|
|
|
},{}],3:[function(_dereq_,module,exports){
|
|
/**
|
|
*
|
|
* VALIDATE: undefined
|
|
*
|
|
*
|
|
* DESCRIPTION:
|
|
* - Validates if a value is undefined.
|
|
*
|
|
*
|
|
* NOTES:
|
|
* [1]
|
|
*
|
|
*
|
|
* TODO:
|
|
* [1]
|
|
*
|
|
*
|
|
* LICENSE:
|
|
* MIT
|
|
*
|
|
* Copyright (c) 2014. Athan Reines.
|
|
*
|
|
*
|
|
* AUTHOR:
|
|
* Athan Reines. kgryte@gmail.com. 2014.
|
|
*
|
|
*/
|
|
|
|
'use strict';
|
|
|
|
/**
|
|
* FUNCTION: isUndefined( value )
|
|
* Validates if a value is undefined.
|
|
*
|
|
* @param {*} value - value to be validated
|
|
* @returns {Boolean} boolean indicating whether value is undefined
|
|
*/
|
|
function isUndefined( value ) {
|
|
return value === void 0;
|
|
} // end FUNCTION isUndefined()
|
|
|
|
|
|
// EXPORTS //
|
|
|
|
module.exports = isUndefined;
|
|
|
|
},{}]},{},[1])(1)
|
|
}); |