source: trip-planner-front/node_modules/lodash/isBuffer.js@ 6fe77af

Last change on this file since 6fe77af was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 1.1 KB
Line 
1var root = require('./_root'),
2 stubFalse = require('./stubFalse');
3
4/** Detect free variable `exports`. */
5var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;
6
7/** Detect free variable `module`. */
8var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;
9
10/** Detect the popular CommonJS extension `module.exports`. */
11var moduleExports = freeModule && freeModule.exports === freeExports;
12
13/** Built-in value references. */
14var Buffer = moduleExports ? root.Buffer : undefined;
15
16/* Built-in method references for those with the same name as other `lodash` methods. */
17var nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;
18
19/**
20 * Checks if `value` is a buffer.
21 *
22 * @static
23 * @memberOf _
24 * @since 4.3.0
25 * @category Lang
26 * @param {*} value The value to check.
27 * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.
28 * @example
29 *
30 * _.isBuffer(new Buffer(2));
31 * // => true
32 *
33 * _.isBuffer(new Uint8Array(2));
34 * // => false
35 */
36var isBuffer = nativeIsBuffer || stubFalse;
37
38module.exports = isBuffer;
Note: See TracBrowser for help on using the repository browser.