mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-05 01:17:50 +00:00
Move internal modules to “internal” folder.
This commit is contained in:
18
.internal/baseIsDate.js
Normal file
18
.internal/baseIsDate.js
Normal file
@@ -0,0 +1,18 @@
|
||||
import baseGetTag from './.internal/baseGetTag.js';
|
||||
import isObjectLike from './isObjectLike.js';
|
||||
|
||||
/** `Object#toString` result references. */
|
||||
const dateTag = '[object Date]';
|
||||
|
||||
/**
|
||||
* The base implementation of `isDate` without Node.js optimizations.
|
||||
*
|
||||
* @private
|
||||
* @param {*} value The value to check.
|
||||
* @returns {boolean} Returns `true` if `value` is a date object, else `false`.
|
||||
*/
|
||||
function baseIsDate(value) {
|
||||
return isObjectLike(value) && baseGetTag(value) == dateTag;
|
||||
}
|
||||
|
||||
export default baseIsDate;
|
||||
Reference in New Issue
Block a user