tiny-essentials 1.10.1 → 1.10.2
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.
package/dist/TinyBasicsEs.js
CHANGED
|
@@ -2696,7 +2696,7 @@ function countObj(obj) {
|
|
|
2696
2696
|
* a value is a clean JSON-compatible object, free of class instances or special types.
|
|
2697
2697
|
*
|
|
2698
2698
|
* @param {unknown} value - The value to test.
|
|
2699
|
-
* @returns {value is Record<
|
|
2699
|
+
* @returns {value is Record<string | number | symbol, unknown>} Returns true if the value is a pure object.
|
|
2700
2700
|
*/
|
|
2701
2701
|
function isJsonObject(value) {
|
|
2702
2702
|
if (value === null || typeof value !== 'object') return false;
|
|
@@ -2826,7 +2826,7 @@ if (isBrowser) {
|
|
|
2826
2826
|
extendObjType([
|
|
2827
2827
|
[
|
|
2828
2828
|
'object',
|
|
2829
|
-
/** @param {*} val @returns {val is Record<
|
|
2829
|
+
/** @param {*} val @returns {val is Record<string | number | symbol, unknown>} */
|
|
2830
2830
|
(val) => isJsonObject(val),
|
|
2831
2831
|
],
|
|
2832
2832
|
]);
|
package/dist/TinyEssentials.js
CHANGED
|
@@ -2953,7 +2953,7 @@ function countObj(obj) {
|
|
|
2953
2953
|
* a value is a clean JSON-compatible object, free of class instances or special types.
|
|
2954
2954
|
*
|
|
2955
2955
|
* @param {unknown} value - The value to test.
|
|
2956
|
-
* @returns {value is Record<
|
|
2956
|
+
* @returns {value is Record<string | number | symbol, unknown>} Returns true if the value is a pure object.
|
|
2957
2957
|
*/
|
|
2958
2958
|
function isJsonObject(value) {
|
|
2959
2959
|
if (value === null || typeof value !== 'object') return false;
|
|
@@ -3083,7 +3083,7 @@ if (isBrowser) {
|
|
|
3083
3083
|
extendObjType([
|
|
3084
3084
|
[
|
|
3085
3085
|
'object',
|
|
3086
|
-
/** @param {*} val @returns {val is Record<
|
|
3086
|
+
/** @param {*} val @returns {val is Record<string | number | symbol, unknown>} */
|
|
3087
3087
|
(val) => isJsonObject(val),
|
|
3088
3088
|
],
|
|
3089
3089
|
]);
|
|
@@ -227,7 +227,7 @@ function countObj(obj) {
|
|
|
227
227
|
* a value is a clean JSON-compatible object, free of class instances or special types.
|
|
228
228
|
*
|
|
229
229
|
* @param {unknown} value - The value to test.
|
|
230
|
-
* @returns {value is Record<
|
|
230
|
+
* @returns {value is Record<string | number | symbol, unknown>} Returns true if the value is a pure object.
|
|
231
231
|
*/
|
|
232
232
|
function isJsonObject(value) {
|
|
233
233
|
if (value === null || typeof value !== 'object') return false;
|
|
@@ -357,7 +357,7 @@ if (isBrowser) {
|
|
|
357
357
|
extendObjType([
|
|
358
358
|
[
|
|
359
359
|
'object',
|
|
360
|
-
/** @param {*} val @returns {val is Record<
|
|
360
|
+
/** @param {*} val @returns {val is Record<string | number | symbol, unknown>} */
|
|
361
361
|
(val) => isJsonObject(val),
|
|
362
362
|
],
|
|
363
363
|
]);
|
|
@@ -101,9 +101,9 @@ export function countObj(obj: Array<any> | Record<string | number, any>): number
|
|
|
101
101
|
* a value is a clean JSON-compatible object, free of class instances or special types.
|
|
102
102
|
*
|
|
103
103
|
* @param {unknown} value - The value to test.
|
|
104
|
-
* @returns {value is Record<
|
|
104
|
+
* @returns {value is Record<string | number | symbol, unknown>} Returns true if the value is a pure object.
|
|
105
105
|
*/
|
|
106
|
-
export function isJsonObject(value: unknown): value is Record<
|
|
106
|
+
export function isJsonObject(value: unknown): value is Record<string | number | symbol, unknown>;
|
|
107
107
|
export type ExtendObjType = {
|
|
108
108
|
[x: string]: (val: any) => any;
|
|
109
109
|
};
|
|
@@ -210,7 +210,7 @@ export function countObj(obj) {
|
|
|
210
210
|
* a value is a clean JSON-compatible object, free of class instances or special types.
|
|
211
211
|
*
|
|
212
212
|
* @param {unknown} value - The value to test.
|
|
213
|
-
* @returns {value is Record<
|
|
213
|
+
* @returns {value is Record<string | number | symbol, unknown>} Returns true if the value is a pure object.
|
|
214
214
|
*/
|
|
215
215
|
export function isJsonObject(value) {
|
|
216
216
|
if (value === null || typeof value !== 'object')
|
|
@@ -336,7 +336,7 @@ if (isBrowser) {
|
|
|
336
336
|
extendObjType([
|
|
337
337
|
[
|
|
338
338
|
'object',
|
|
339
|
-
/** @param {*} val @returns {val is Record<
|
|
339
|
+
/** @param {*} val @returns {val is Record<string | number | symbol, unknown>} */
|
|
340
340
|
(val) => isJsonObject(val),
|
|
341
341
|
],
|
|
342
342
|
]);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tiny-essentials",
|
|
3
|
-
"version": "1.10.
|
|
3
|
+
"version": "1.10.2",
|
|
4
4
|
"description": "Collection of small, essential scripts designed to be used across various projects. These simple utilities are crafted for speed, ease of use, and versatility.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "npm run test:mjs && npm run test:cjs && npm run test:js",
|