@duplojs/utils 1.1.8 → 1.1.9
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/array/reduce.cjs +1 -0
- package/dist/array/reduce.mjs +1 -0
- package/dist/array/reduceRight.cjs +1 -0
- package/dist/array/reduceRight.mjs +1 -0
- package/dist/common/globalStore.cjs +21 -0
- package/dist/common/globalStore.d.ts +7 -0
- package/dist/common/globalStore.mjs +19 -0
- package/dist/common/index.d.ts +1 -0
- package/dist/common/instanceOf.cjs +1 -0
- package/dist/common/instanceOf.mjs +1 -0
- package/dist/common/kind.cjs +5 -3
- package/dist/common/kind.d.ts +12 -5
- package/dist/common/kind.mjs +5 -4
- package/dist/common/wrapValue.cjs +4 -0
- package/dist/common/wrapValue.d.ts +1 -0
- package/dist/common/wrapValue.mjs +4 -1
- package/dist/dataParser/base.cjs +1 -0
- package/dist/dataParser/base.mjs +1 -0
- package/dist/dataParser/baseExtended.cjs +1 -0
- package/dist/dataParser/baseExtended.mjs +1 -0
- package/dist/dataParser/extended/array.cjs +1 -0
- package/dist/dataParser/extended/array.mjs +1 -0
- package/dist/dataParser/extended/bigint.cjs +1 -0
- package/dist/dataParser/extended/bigint.mjs +1 -0
- package/dist/dataParser/extended/boolean.cjs +1 -0
- package/dist/dataParser/extended/boolean.mjs +1 -0
- package/dist/dataParser/extended/coerce/bigint.cjs +1 -0
- package/dist/dataParser/extended/coerce/bigint.mjs +1 -0
- package/dist/dataParser/extended/coerce/boolean.cjs +1 -0
- package/dist/dataParser/extended/coerce/boolean.mjs +1 -0
- package/dist/dataParser/extended/coerce/empty.cjs +1 -0
- package/dist/dataParser/extended/coerce/empty.mjs +1 -0
- package/dist/dataParser/extended/coerce/nil.cjs +1 -0
- package/dist/dataParser/extended/coerce/nil.mjs +1 -0
- package/dist/dataParser/extended/coerce/number.cjs +1 -0
- package/dist/dataParser/extended/coerce/number.mjs +1 -0
- package/dist/dataParser/extended/coerce/string.cjs +1 -0
- package/dist/dataParser/extended/coerce/string.mjs +1 -0
- package/dist/dataParser/extended/empty.cjs +1 -0
- package/dist/dataParser/extended/empty.mjs +1 -0
- package/dist/dataParser/extended/lazy.cjs +1 -0
- package/dist/dataParser/extended/lazy.mjs +1 -0
- package/dist/dataParser/extended/literal.cjs +1 -0
- package/dist/dataParser/extended/literal.mjs +1 -0
- package/dist/dataParser/extended/nil.cjs +1 -0
- package/dist/dataParser/extended/nil.mjs +1 -0
- package/dist/dataParser/extended/nullable.cjs +1 -0
- package/dist/dataParser/extended/nullable.mjs +1 -0
- package/dist/dataParser/extended/number.cjs +1 -0
- package/dist/dataParser/extended/number.mjs +1 -0
- package/dist/dataParser/extended/object.cjs +1 -0
- package/dist/dataParser/extended/object.mjs +1 -0
- package/dist/dataParser/extended/optional.cjs +1 -0
- package/dist/dataParser/extended/optional.mjs +1 -0
- package/dist/dataParser/extended/pipe.cjs +1 -0
- package/dist/dataParser/extended/pipe.mjs +1 -0
- package/dist/dataParser/extended/record.cjs +1 -0
- package/dist/dataParser/extended/record.mjs +1 -0
- package/dist/dataParser/extended/string.cjs +1 -0
- package/dist/dataParser/extended/string.mjs +1 -0
- package/dist/dataParser/extended/templateLiteral.cjs +1 -0
- package/dist/dataParser/extended/templateLiteral.mjs +1 -0
- package/dist/dataParser/extended/transform.cjs +1 -0
- package/dist/dataParser/extended/transform.mjs +1 -0
- package/dist/dataParser/extended/tuple.cjs +1 -0
- package/dist/dataParser/extended/tuple.mjs +1 -0
- package/dist/dataParser/extended/union.cjs +1 -0
- package/dist/dataParser/extended/union.mjs +1 -0
- package/dist/dataParser/extended/unknown.cjs +1 -0
- package/dist/dataParser/extended/unknown.mjs +1 -0
- package/dist/dataParser/kind.cjs +4 -1
- package/dist/dataParser/kind.d.ts +1 -1
- package/dist/dataParser/kind.mjs +4 -1
- package/dist/dataParser/parsers/coerce/bigint.cjs +1 -0
- package/dist/dataParser/parsers/coerce/bigint.mjs +1 -0
- package/dist/dataParser/parsers/coerce/boolean.cjs +1 -0
- package/dist/dataParser/parsers/coerce/boolean.mjs +1 -0
- package/dist/dataParser/parsers/coerce/empty.cjs +1 -0
- package/dist/dataParser/parsers/coerce/empty.mjs +1 -0
- package/dist/dataParser/parsers/coerce/nil.cjs +1 -0
- package/dist/dataParser/parsers/coerce/nil.mjs +1 -0
- package/dist/dataParser/parsers/coerce/number.cjs +1 -0
- package/dist/dataParser/parsers/coerce/number.mjs +1 -0
- package/dist/dataParser/parsers/coerce/string.cjs +1 -0
- package/dist/dataParser/parsers/coerce/string.mjs +1 -0
- package/dist/dataParser/parsers/literal.cjs +1 -0
- package/dist/dataParser/parsers/literal.mjs +1 -0
- package/dist/dataParser/parsers/object.cjs +1 -0
- package/dist/dataParser/parsers/object.mjs +1 -0
- package/dist/dataParser/parsers/templateLiteral.cjs +1 -0
- package/dist/dataParser/parsers/templateLiteral.mjs +1 -0
- package/dist/either/bool/falsy.cjs +1 -0
- package/dist/either/bool/falsy.mjs +1 -0
- package/dist/either/bool/truthy.cjs +1 -0
- package/dist/either/bool/truthy.mjs +1 -0
- package/dist/either/future/create.cjs +1 -0
- package/dist/either/future/create.mjs +1 -0
- package/dist/either/future/error.cjs +1 -0
- package/dist/either/future/error.mjs +1 -0
- package/dist/either/future/success.cjs +1 -0
- package/dist/either/future/success.mjs +1 -0
- package/dist/either/kind.cjs +4 -1
- package/dist/either/kind.d.ts +1 -1
- package/dist/either/kind.mjs +4 -1
- package/dist/either/left/when.cjs +1 -0
- package/dist/either/left/when.mjs +1 -0
- package/dist/either/nullable/empty.cjs +1 -0
- package/dist/either/nullable/empty.mjs +1 -0
- package/dist/either/nullable/filled.cjs +1 -0
- package/dist/either/nullable/filled.mjs +1 -0
- package/dist/either/nullish/empty.cjs +1 -0
- package/dist/either/nullish/empty.mjs +1 -0
- package/dist/either/nullish/filled.cjs +1 -0
- package/dist/either/nullish/filled.mjs +1 -0
- package/dist/either/optional/empty.cjs +1 -0
- package/dist/either/optional/empty.mjs +1 -0
- package/dist/either/optional/filled.cjs +1 -0
- package/dist/either/optional/filled.mjs +1 -0
- package/dist/either/right/asyncPipe.cjs +1 -0
- package/dist/either/right/asyncPipe.mjs +1 -0
- package/dist/either/right/pipe.cjs +1 -0
- package/dist/either/right/pipe.mjs +1 -0
- package/dist/either/right/when.cjs +1 -0
- package/dist/either/right/when.mjs +1 -0
- package/dist/either/whenHasInformation.cjs +1 -0
- package/dist/either/whenHasInformation.mjs +1 -0
- package/dist/generator/asyncReduce.cjs +1 -0
- package/dist/generator/asyncReduce.mjs +1 -0
- package/dist/generator/reduce.cjs +1 -0
- package/dist/generator/reduce.mjs +1 -0
- package/dist/index.cjs +4 -0
- package/dist/index.mjs +3 -2
- package/dist/object/deepDiscriminate.cjs +1 -0
- package/dist/object/deepDiscriminate.mjs +1 -0
- package/dist/object/discriminate.cjs +1 -0
- package/dist/object/discriminate.mjs +1 -0
- package/dist/object/entries.cjs +3 -1
- package/dist/object/entries.mjs +4 -2
- package/dist/object/keys.cjs +3 -1
- package/dist/object/keys.mjs +4 -2
- package/dist/pattern/exhaustive.cjs +1 -0
- package/dist/pattern/exhaustive.mjs +1 -0
- package/dist/pattern/otherwise.cjs +1 -0
- package/dist/pattern/otherwise.mjs +1 -0
- package/dist/pattern/result.cjs +1 -0
- package/dist/pattern/result.mjs +1 -0
- package/dist/string/types/forbiddenString.d.ts +8 -0
- package/dist/string/types/index.d.ts +1 -1
- package/package.json +1 -1
- package/dist/string/types/forbiddenCharacters.d.ts +0 -5
package/dist/dataParser/kind.cjs
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var kind = require('../common/kind.cjs');
|
|
4
|
+
require('../common/globalStore.cjs');
|
|
4
5
|
|
|
5
|
-
const createDataParserKind = kind.createKindNamespace(
|
|
6
|
+
const createDataParserKind = kind.createKindNamespace(
|
|
7
|
+
// @ts-expect-error reserved kind namespace
|
|
8
|
+
"DataParser");
|
|
6
9
|
|
|
7
10
|
exports.createDataParserKind = createDataParserKind;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const createDataParserKind: <GenericName extends string, GenericKindValue extends unknown = unknown>(name: GenericName & import("../string").
|
|
1
|
+
export declare const createDataParserKind: <GenericName extends string, GenericKindValue extends unknown = unknown>(name: GenericName & import("../string").ForbiddenString<GenericName, "@" | "/">) => import("../common").KindHandler<import("../common").KindDefinition<`@DataParser/${GenericName}`, GenericKindValue>>;
|
package/dist/dataParser/kind.mjs
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
import { createKindNamespace } from '../common/kind.mjs';
|
|
2
|
+
import '../common/globalStore.mjs';
|
|
2
3
|
|
|
3
|
-
const createDataParserKind = createKindNamespace(
|
|
4
|
+
const createDataParserKind = createKindNamespace(
|
|
5
|
+
// @ts-expect-error reserved kind namespace
|
|
6
|
+
"DataParser");
|
|
4
7
|
|
|
5
8
|
export { createDataParserKind };
|
|
@@ -6,6 +6,7 @@ var forward = require('../../common/forward.cjs');
|
|
|
6
6
|
var memo = require('../../common/memo.cjs');
|
|
7
7
|
var filter = require('../../array/filter.cjs');
|
|
8
8
|
var map = require('../../array/map.cjs');
|
|
9
|
+
require('../../common/globalStore.cjs');
|
|
9
10
|
var base = require('../base.cjs');
|
|
10
11
|
var error = require('../error.cjs');
|
|
11
12
|
var kind = require('../kind.cjs');
|
|
@@ -4,6 +4,7 @@ import { forward } from '../../common/forward.mjs';
|
|
|
4
4
|
import { memo } from '../../common/memo.mjs';
|
|
5
5
|
import { filter } from '../../array/filter.mjs';
|
|
6
6
|
import { map } from '../../array/map.mjs';
|
|
7
|
+
import '../../common/globalStore.mjs';
|
|
7
8
|
import { dataParserInit, SymbolDataParserError, dataParserKind } from '../base.mjs';
|
|
8
9
|
import { SymbolDataParserErrorIssue, setErrorPath, popErrorPath } from '../error.mjs';
|
|
9
10
|
import { createDataParserKind } from '../kind.mjs';
|
|
@@ -8,6 +8,7 @@ var isType = require('../../common/isType.cjs');
|
|
|
8
8
|
var whenElse = require('../../common/whenElse.cjs');
|
|
9
9
|
var map = require('../../array/map.cjs');
|
|
10
10
|
var join = require('../../array/join.cjs');
|
|
11
|
+
require('../../common/globalStore.cjs');
|
|
11
12
|
var base = require('../base.cjs');
|
|
12
13
|
var error = require('../error.cjs');
|
|
13
14
|
require('../../pattern/result.cjs');
|
|
@@ -6,6 +6,7 @@ import { isType } from '../../common/isType.mjs';
|
|
|
6
6
|
import { whenElse } from '../../common/whenElse.mjs';
|
|
7
7
|
import { map } from '../../array/map.mjs';
|
|
8
8
|
import { join } from '../../array/join.mjs';
|
|
9
|
+
import '../../common/globalStore.mjs';
|
|
9
10
|
import { dataParserInit } from '../base.mjs';
|
|
10
11
|
import { SymbolDataParserErrorIssue } from '../error.mjs';
|
|
11
12
|
import '../../pattern/result.mjs';
|
package/dist/either/kind.cjs
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var kind = require('../common/kind.cjs');
|
|
4
|
+
require('../common/globalStore.cjs');
|
|
4
5
|
|
|
5
|
-
const createEitherKind = kind.createKindNamespace(
|
|
6
|
+
const createEitherKind = kind.createKindNamespace(
|
|
7
|
+
// @ts-expect-error reserved kind namespace
|
|
8
|
+
"Either");
|
|
6
9
|
const eitherInformationKind = createEitherKind("information");
|
|
7
10
|
|
|
8
11
|
exports.createEitherKind = createEitherKind;
|
package/dist/either/kind.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const createEitherKind: <GenericName extends string, GenericKindValue extends unknown = unknown>(name: GenericName & import("../string").
|
|
1
|
+
export declare const createEitherKind: <GenericName extends string, GenericKindValue extends unknown = unknown>(name: GenericName & import("../string").ForbiddenString<GenericName, "@" | "/">) => import("../common").KindHandler<import("../common").KindDefinition<`@Either/${GenericName}`, GenericKindValue>>;
|
|
2
2
|
export declare const eitherInformationKind: import("../common").KindHandler<import("../common").KindDefinition<"@Either/information", string>>;
|
package/dist/either/kind.mjs
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { createKindNamespace } from '../common/kind.mjs';
|
|
2
|
+
import '../common/globalStore.mjs';
|
|
2
3
|
|
|
3
|
-
const createEitherKind = createKindNamespace(
|
|
4
|
+
const createEitherKind = createKindNamespace(
|
|
5
|
+
// @ts-expect-error reserved kind namespace
|
|
6
|
+
"Either");
|
|
4
7
|
const eitherInformationKind = createEitherKind("information");
|
|
5
8
|
|
|
6
9
|
export { createEitherKind, eitherInformationKind };
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
var kind = require('../kind.cjs');
|
|
4
4
|
var is$1 = require('../left/is.cjs');
|
|
5
5
|
var unwrap = require('../../common/unwrap.cjs');
|
|
6
|
+
require('../../common/globalStore.cjs');
|
|
6
7
|
var create = require('../right/create.cjs');
|
|
7
8
|
var is = require('../right/is.cjs');
|
|
8
9
|
var create$1 = require('./create.cjs');
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { createEitherKind } from '../kind.mjs';
|
|
2
2
|
import { isLeft } from '../left/is.mjs';
|
|
3
3
|
import { unwrap } from '../../common/unwrap.mjs';
|
|
4
|
+
import '../../common/globalStore.mjs';
|
|
4
5
|
import { right } from '../right/create.mjs';
|
|
5
6
|
import { isRight } from '../right/is.mjs';
|
|
6
7
|
import { nullish } from './create.mjs';
|
|
@@ -5,6 +5,7 @@ var base = require('./base.cjs');
|
|
|
5
5
|
var create$1 = require('./create.cjs');
|
|
6
6
|
var create = require('../left/create.cjs');
|
|
7
7
|
var is = require('../left/is.cjs');
|
|
8
|
+
require('../../common/globalStore.cjs');
|
|
8
9
|
var is$1 = require('../right/is.cjs');
|
|
9
10
|
|
|
10
11
|
const eitherOptionalEmptyKind = kind.createEitherKind("optional-empty");
|
|
@@ -3,6 +3,7 @@ import { eitherOptionalKind } from './base.mjs';
|
|
|
3
3
|
import { optional } from './create.mjs';
|
|
4
4
|
import { left } from '../left/create.mjs';
|
|
5
5
|
import { isLeft } from '../left/is.mjs';
|
|
6
|
+
import '../../common/globalStore.mjs';
|
|
6
7
|
import { isRight } from '../right/is.mjs';
|
|
7
8
|
|
|
8
9
|
const eitherOptionalEmptyKind = createEitherKind("optional-empty");
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
var kind = require('../common/kind.cjs');
|
|
4
4
|
var wrapValue = require('../common/wrapValue.cjs');
|
|
5
5
|
var unwrap = require('../common/unwrap.cjs');
|
|
6
|
+
require('../common/globalStore.cjs');
|
|
6
7
|
var override = require('../object/override.cjs');
|
|
7
8
|
|
|
8
9
|
const generatorReduceFromKind = kind.createKind("generator-reduce-from");
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { createKind } from '../common/kind.mjs';
|
|
2
2
|
import { wrapValue } from '../common/wrapValue.mjs';
|
|
3
3
|
import { unwrap } from '../common/unwrap.mjs';
|
|
4
|
+
import '../common/globalStore.mjs';
|
|
4
5
|
import { override } from '../object/override.mjs';
|
|
5
6
|
|
|
6
7
|
const generatorReduceFromKind = createKind("generator-reduce-from");
|
package/dist/index.cjs
CHANGED
|
@@ -37,6 +37,7 @@ var whenElse = require('./common/whenElse.cjs');
|
|
|
37
37
|
var justReturn = require('./common/justReturn.cjs');
|
|
38
38
|
var memo = require('./common/memo.cjs');
|
|
39
39
|
var instanceOf = require('./common/instanceOf.cjs');
|
|
40
|
+
var globalStore = require('./common/globalStore.cjs');
|
|
40
41
|
var index = require('./array/index.cjs');
|
|
41
42
|
var index$1 = require('./number/index.cjs');
|
|
42
43
|
var index$2 = require('./either/index.cjs');
|
|
@@ -59,6 +60,7 @@ exports.createExternalPromise = externalPromise.createExternalPromise;
|
|
|
59
60
|
exports.createInterpolation = interpolation.createInterpolation;
|
|
60
61
|
exports.createKind = kind.createKind;
|
|
61
62
|
exports.createKindNamespace = kind.createKindNamespace;
|
|
63
|
+
exports.isRuntimeKind = kind.isRuntimeKind;
|
|
62
64
|
exports.keyKindPrefix = kind.keyKindPrefix;
|
|
63
65
|
exports.kindHeritage = kind.kindHeritage;
|
|
64
66
|
exports.pipe = pipe.pipe;
|
|
@@ -76,6 +78,7 @@ exports.unwrap = unwrap.unwrap;
|
|
|
76
78
|
exports.asyncLoop = asyncLoop.asyncLoop;
|
|
77
79
|
exports.createAsyncRetry = asyncRetry.createAsyncRetry;
|
|
78
80
|
exports.useAsyncRetry = asyncRetry.useAsyncRetry;
|
|
81
|
+
exports.isRuntimeWrappedValueKey = wrapValue.isRuntimeWrappedValueKey;
|
|
79
82
|
exports.isWrappedValue = wrapValue.isWrappedValue;
|
|
80
83
|
exports.keyWrappedValue = wrapValue.keyWrappedValue;
|
|
81
84
|
exports.wrapValue = wrapValue.wrapValue;
|
|
@@ -95,6 +98,7 @@ exports.whenElse = whenElse.whenElse;
|
|
|
95
98
|
exports.justReturn = justReturn.justReturn;
|
|
96
99
|
exports.memo = memo.memo;
|
|
97
100
|
exports.instanceOf = instanceOf.instanceOf;
|
|
101
|
+
exports.createGlobalStore = globalStore.createGlobalStore;
|
|
98
102
|
exports.A = index;
|
|
99
103
|
exports.DArray = index;
|
|
100
104
|
exports.DNumber = index$1;
|
package/dist/index.mjs
CHANGED
|
@@ -5,7 +5,7 @@ export { createEnum } from './common/enum.mjs';
|
|
|
5
5
|
export { escapeRegExp } from './common/escapeRegExp.mjs';
|
|
6
6
|
export { createExternalPromise } from './common/externalPromise.mjs';
|
|
7
7
|
export { createInterpolation } from './common/interpolation.mjs';
|
|
8
|
-
export { createKind, createKindNamespace, keyKindPrefix, kindHeritage } from './common/kind.mjs';
|
|
8
|
+
export { createKind, createKindNamespace, isRuntimeKind, keyKindPrefix, kindHeritage } from './common/kind.mjs';
|
|
9
9
|
export { pipe } from './common/pipe.mjs';
|
|
10
10
|
export { promiseObject } from './common/promiseObject.mjs';
|
|
11
11
|
export { simpleClone } from './common/simpleClone.mjs';
|
|
@@ -18,7 +18,7 @@ export { toWrappedValue } from './common/toWrappedValue.mjs';
|
|
|
18
18
|
export { unwrap } from './common/unwrap.mjs';
|
|
19
19
|
export { asyncLoop } from './common/asyncLoop.mjs';
|
|
20
20
|
export { createAsyncRetry, useAsyncRetry } from './common/asyncRetry.mjs';
|
|
21
|
-
export { isWrappedValue, keyWrappedValue, wrapValue } from './common/wrapValue.mjs';
|
|
21
|
+
export { isRuntimeWrappedValueKey, isWrappedValue, keyWrappedValue, wrapValue } from './common/wrapValue.mjs';
|
|
22
22
|
export { toString } from './common/toString.mjs';
|
|
23
23
|
export { innerPipe } from './common/innerPipe.mjs';
|
|
24
24
|
export { asyncInnerPipe } from './common/asyncInnerPipe.mjs';
|
|
@@ -35,6 +35,7 @@ export { whenElse } from './common/whenElse.mjs';
|
|
|
35
35
|
export { justReturn } from './common/justReturn.mjs';
|
|
36
36
|
export { memo } from './common/memo.mjs';
|
|
37
37
|
export { instanceOf } from './common/instanceOf.mjs';
|
|
38
|
+
export { createGlobalStore } from './common/globalStore.mjs';
|
|
38
39
|
import * as index from './array/index.mjs';
|
|
39
40
|
export { index as A };
|
|
40
41
|
export { index as DArray };
|