PageRenderTime 21ms CodeModel.GetById 17ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/node_modules/lodash/isSet.js

https://bitbucket.org/coleman333/smartsite
JavaScript | 27 lines | 6 code | 3 blank | 18 comment | 1 complexity | 69b99972f1579175354ab86769b0a000 MD5 | raw file
 1var baseIsSet = require('./_baseIsSet'),
 2    baseUnary = require('./_baseUnary'),
 3    nodeUtil = require('./_nodeUtil');
 4
 5/* Node.js helper references. */
 6var nodeIsSet = nodeUtil && nodeUtil.isSet;
 7
 8/**
 9 * Checks if `value` is classified as a `Set` object.
10 *
11 * @static
12 * @memberOf _
13 * @since 4.3.0
14 * @category Lang
15 * @param {*} value The value to check.
16 * @returns {boolean} Returns `true` if `value` is a set, else `false`.
17 * @example
18 *
19 * _.isSet(new Set);
20 * // => true
21 *
22 * _.isSet(new WeakSet);
23 * // => false
24 */
25var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;
26
27module.exports = isSet;