_baseIsArrayBuffer.js 502 B

1234567891011121314151617
  1. import baseGetTag from './_baseGetTag.js';
  2. import isObjectLike from './isObjectLike.js';
  3. var arrayBufferTag = '[object ArrayBuffer]';
  4. /**
  5. * The base implementation of `_.isArrayBuffer` without Node.js optimizations.
  6. *
  7. * @private
  8. * @param {*} value The value to check.
  9. * @returns {boolean} Returns `true` if `value` is an array buffer, else `false`.
  10. */
  11. function baseIsArrayBuffer(value) {
  12. return isObjectLike(value) && baseGetTag(value) == arrayBufferTag;
  13. }
  14. export default baseIsArrayBuffer;