@webdeveric/utils 0.65.0 → 0.66.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -25,6 +25,7 @@ __exportStar(require("./isBigIntArray.js"), exports);
25
25
  __exportStar(require("./isBinaryNumberString.js"), exports);
26
26
  __exportStar(require("./isBoolean.js"), exports);
27
27
  __exportStar(require("./isBooleanArray.js"), exports);
28
+ __exportStar(require("./isDateString.js"), exports);
28
29
  __exportStar(require("./isDigitsString.js"), exports);
29
30
  __exportStar(require("./isFiniteNumber.js"), exports);
30
31
  __exportStar(require("./isFunction.js"), exports);
@@ -44,6 +45,7 @@ __exportStar(require("./isNumericString.js"), exports);
44
45
  __exportStar(require("./isNumericValue.js"), exports);
45
46
  __exportStar(require("./isNumericValueArray.js"), exports);
46
47
  __exportStar(require("./isObject.js"), exports);
48
+ __exportStar(require("./isObjectLiteral.js"), exports);
47
49
  __exportStar(require("./isObjectWith.js"), exports);
48
50
  __exportStar(require("./isOctalNumberString.js"), exports);
49
51
  __exportStar(require("./isOptionalArray.js"), exports);
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isDateString = void 0;
4
+ const isDateString = (input) => typeof input === 'string' && !Number.isNaN(new Date(input).getTime());
5
+ exports.isDateString = isDateString;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isObjectLiteral = void 0;
4
+ const isObjectLiteral = (input) => input !== null && typeof input === 'object' && Object.getPrototypeOf(input) === Object.prototype;
5
+ exports.isObjectLiteral = isObjectLiteral;
@@ -9,6 +9,7 @@ export * from './isBigIntArray.js';
9
9
  export * from './isBinaryNumberString.js';
10
10
  export * from './isBoolean.js';
11
11
  export * from './isBooleanArray.js';
12
+ export * from './isDateString.js';
12
13
  export * from './isDigitsString.js';
13
14
  export * from './isFiniteNumber.js';
14
15
  export * from './isFunction.js';
@@ -28,6 +29,7 @@ export * from './isNumericString.js';
28
29
  export * from './isNumericValue.js';
29
30
  export * from './isNumericValueArray.js';
30
31
  export * from './isObject.js';
32
+ export * from './isObjectLiteral.js';
31
33
  export * from './isObjectWith.js';
32
34
  export * from './isOctalNumberString.js';
33
35
  export * from './isOptionalArray.js';
@@ -0,0 +1 @@
1
+ export const isDateString = (input) => typeof input === 'string' && !Number.isNaN(new Date(input).getTime());
@@ -0,0 +1 @@
1
+ export const isObjectLiteral = (input) => input !== null && typeof input === 'object' && Object.getPrototypeOf(input) === Object.prototype;
@@ -9,6 +9,7 @@ export * from './isBigIntArray.js';
9
9
  export * from './isBinaryNumberString.js';
10
10
  export * from './isBoolean.js';
11
11
  export * from './isBooleanArray.js';
12
+ export * from './isDateString.js';
12
13
  export * from './isDigitsString.js';
13
14
  export * from './isFiniteNumber.js';
14
15
  export * from './isFunction.js';
@@ -28,6 +29,7 @@ export * from './isNumericString.js';
28
29
  export * from './isNumericValue.js';
29
30
  export * from './isNumericValueArray.js';
30
31
  export * from './isObject.js';
32
+ export * from './isObjectLiteral.js';
31
33
  export * from './isObjectWith.js';
32
34
  export * from './isOctalNumberString.js';
33
35
  export * from './isOptionalArray.js';
@@ -0,0 +1,2 @@
1
+ import type { TypePredicateFn } from '../types/functions.js';
2
+ export declare const isDateString: TypePredicateFn<string>;
@@ -0,0 +1,2 @@
1
+ import type { UnknownRecord } from '../types/records.js';
2
+ export declare const isObjectLiteral: (input: unknown) => input is UnknownRecord;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@webdeveric/utils",
3
3
  "description": "Just another collection of utilities.",
4
- "version": "0.65.0",
4
+ "version": "0.66.0",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },