53fd3cc9b739702c93d3645f156a96c21e445035943b5f02c77ae4f1a50f8e6e6ae14019a1f28a93bd3e82a6fcc5f8ad02cdb599bb8973d7e4e84bfee43d1e 953 B

123456789101112131415161718192021222324
  1. import { isArray, isObject, isString } from '@vue/shared';
  2. export { isArray, isDate, isFunction, isObject, isPlainObject, isPromise, isString, isSymbol } from '@vue/shared';
  3. import { isNil } from 'lodash-unified';
  4. const isUndefined = (val) => val === void 0;
  5. const isBoolean = (val) => typeof val === "boolean";
  6. const isNumber = (val) => typeof val === "number";
  7. const isEmpty = (val) => !val && val !== 0 || isArray(val) && val.length === 0 || isObject(val) && !Object.keys(val).length;
  8. const isElement = (e) => {
  9. if (typeof Element === "undefined")
  10. return false;
  11. return e instanceof Element;
  12. };
  13. const isPropAbsent = (prop) => isNil(prop);
  14. const isStringNumber = (val) => {
  15. if (!isString(val)) {
  16. return false;
  17. }
  18. return !Number.isNaN(Number(val));
  19. };
  20. const isWindow = (val) => val === window;
  21. export { isBoolean, isElement, isEmpty, isNumber, isPropAbsent, isStringNumber, isUndefined, isWindow };
  22. //# sourceMappingURL=types.mjs.map