arktype 1.0.9-alpha → 1.0.11-alpha
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/README.md +53 -39
- package/dist/cjs/main.js +26 -18
- package/dist/cjs/nodes/branch.js +18 -18
- package/dist/cjs/nodes/compose.js +28 -11
- package/dist/cjs/nodes/discriminate.js +27 -27
- package/dist/cjs/nodes/node.js +24 -24
- package/dist/cjs/nodes/predicate.js +17 -17
- package/dist/cjs/nodes/rules/class.js +5 -5
- package/dist/cjs/nodes/rules/collapsibleSet.js +3 -3
- package/dist/cjs/nodes/rules/divisor.js +2 -2
- package/dist/cjs/nodes/rules/props.js +19 -19
- package/dist/cjs/nodes/rules/range.js +6 -6
- package/dist/cjs/nodes/rules/regex.js +3 -3
- package/dist/cjs/nodes/rules/rules.js +20 -20
- package/dist/cjs/parse/ast/config.js +2 -2
- package/dist/cjs/parse/ast/distributableFunction.js +9 -9
- package/dist/cjs/parse/ast/intersection.js +5 -5
- package/dist/cjs/parse/ast/keyof.js +31 -30
- package/dist/cjs/parse/ast/morph.js +10 -10
- package/dist/cjs/parse/ast/narrow.js +6 -6
- package/dist/cjs/parse/ast/tuple.js +21 -21
- package/dist/cjs/parse/definition.js +18 -20
- package/dist/cjs/parse/record.js +4 -4
- package/dist/cjs/parse/string/reduce/dynamic.js +44 -26
- package/dist/cjs/parse/string/reduce/shared.js +2 -2
- package/dist/cjs/parse/string/shift/operand/enclosed.js +2 -2
- package/dist/cjs/parse/string/shift/operand/operand.js +3 -3
- package/dist/cjs/parse/string/shift/operand/unenclosed.js +3 -3
- package/dist/cjs/parse/string/shift/operator/bounds.js +18 -18
- package/dist/cjs/parse/string/shift/operator/divisor.js +6 -6
- package/dist/cjs/parse/string/shift/operator/operator.js +6 -6
- package/dist/cjs/parse/string/shift/scanner.js +16 -1
- package/dist/cjs/parse/string/string.js +8 -8
- package/dist/cjs/scopes/ark.js +15 -15
- package/dist/cjs/scopes/cache.js +16 -3
- package/dist/cjs/scopes/expressions.js +9 -9
- package/dist/cjs/scopes/jsObjects.js +2 -42
- package/dist/cjs/scopes/scope.js +59 -31
- package/dist/cjs/scopes/tsKeywords.js +2 -2
- package/dist/cjs/scopes/type.js +6 -5
- package/dist/cjs/scopes/validation/creditCard.js +2 -2
- package/dist/cjs/scopes/validation/date.js +4 -4
- package/dist/cjs/scopes/validation/validation.js +17 -17
- package/dist/cjs/traverse/problems.js +41 -21
- package/dist/cjs/traverse/traverse.js +56 -31
- package/dist/cjs/utils/data.js +18 -4
- package/dist/cjs/utils/generics.js +3 -3
- package/dist/cjs/utils/numericLiterals.js +4 -4
- package/dist/cjs/utils/objectKinds.js +4 -4
- package/dist/cjs/utils/serialize.js +6 -6
- package/dist/mjs/main.js +5 -1
- package/dist/mjs/nodes/compose.js +17 -0
- package/dist/mjs/parse/ast/config.js +5 -1
- package/dist/mjs/parse/ast/keyof.js +2 -1
- package/dist/mjs/parse/definition.js +0 -1
- package/dist/mjs/parse/string/reduce/dynamic.js +18 -0
- package/dist/mjs/parse/string/shift/scanner.js +16 -1
- package/dist/mjs/scopes/cache.js +14 -1
- package/dist/mjs/scopes/expressions.js +88 -8
- package/dist/mjs/scopes/jsObjects.js +4 -41
- package/dist/mjs/scopes/scope.js +30 -2
- package/dist/mjs/scopes/tsKeywords.js +18 -1
- package/dist/mjs/scopes/type.js +1 -0
- package/dist/mjs/scopes/validation/validation.js +19 -1
- package/dist/mjs/traverse/problems.js +22 -2
- package/dist/mjs/traverse/traverse.js +25 -0
- package/dist/mjs/utils/data.js +14 -0
- package/dist/tsconfig.temp.tsbuildinfo +1 -1
- package/dist/types/main.d.ts +8 -1
- package/dist/types/nodes/node.d.ts +6 -0
- package/dist/types/parse/ast/bound.d.ts +14 -0
- package/dist/types/parse/ast/config.d.ts +5 -0
- package/dist/types/parse/ast/divisor.d.ts +5 -0
- package/dist/types/parse/definition.d.ts +2 -4
- package/dist/types/parse/string/reduce/static.d.ts +12 -2
- package/dist/types/parse/string/shift/operand/operand.d.ts +3 -3
- package/dist/types/parse/string/shift/operand/unenclosed.d.ts +5 -5
- package/dist/types/parse/string/string.d.ts +1 -2
- package/dist/types/scopes/ark.d.ts +10 -22
- package/dist/types/scopes/expressions.d.ts +88 -0
- package/dist/types/scopes/jsObjects.d.ts +4 -10
- package/dist/types/scopes/tsKeywords.d.ts +18 -0
- package/dist/types/scopes/type.d.ts +4 -2
- package/dist/types/scopes/validation/validation.d.ts +19 -0
- package/dist/types/utils/generics.d.ts +2 -2
- package/package.json +17 -18
|
@@ -18,13 +18,101 @@ export type Expressions<$> = {
|
|
|
18
18
|
morph: FunctionalExpressionParser<$, "|>">;
|
|
19
19
|
};
|
|
20
20
|
type Ark = Expressions<PrecompiledDefaults>;
|
|
21
|
+
/**
|
|
22
|
+
* @operator {@link intersection | &}
|
|
23
|
+
* @docgenTable
|
|
24
|
+
* @string "L&R"
|
|
25
|
+
* @tuple [L, "&", R]
|
|
26
|
+
* @helper intersection(L,R)
|
|
27
|
+
* @example string
|
|
28
|
+
* const intersection = type("/@arktype\.io$/ & email")
|
|
29
|
+
* @example tuple
|
|
30
|
+
* const tupleIntersection = type(["/@arktype\.io$/", "&", "email"])
|
|
31
|
+
* @example helper
|
|
32
|
+
* const helperIntersection = intersection("/@arktype\.io$/","email")
|
|
33
|
+
*/
|
|
21
34
|
export declare const intersection: Ark["intersection"];
|
|
35
|
+
/**
|
|
36
|
+
* @operator {@link union | |}
|
|
37
|
+
* @docgenTable
|
|
38
|
+
* @string "L|R"
|
|
39
|
+
* @tuple [L, "|" , R]
|
|
40
|
+
* @helper union(L,R)
|
|
41
|
+
* @example string
|
|
42
|
+
* const union = type("string|number")
|
|
43
|
+
* @example tuple
|
|
44
|
+
* const tupleUnion = type(["string", "|", "number"])
|
|
45
|
+
* @example helper
|
|
46
|
+
* const helperUnion = union("string", "number")
|
|
47
|
+
*/
|
|
22
48
|
export declare const union: Ark["union"];
|
|
49
|
+
/**
|
|
50
|
+
* @operator {@link arrayOf}
|
|
51
|
+
* @docgenTable
|
|
52
|
+
* @string "T[]"
|
|
53
|
+
* @tuple [T, "[]"]
|
|
54
|
+
* @helper arrayOf(T)
|
|
55
|
+
* @example string
|
|
56
|
+
* const numberArray = type("number[]")
|
|
57
|
+
* @example tuple
|
|
58
|
+
* const tupleArray = type(["number", "[]"])
|
|
59
|
+
* @example helper
|
|
60
|
+
* const helperArray = arrayOf("number")
|
|
61
|
+
*/
|
|
23
62
|
export declare const arrayOf: Ark["arrayOf"];
|
|
63
|
+
/**
|
|
64
|
+
* @operator {@link keyOf}
|
|
65
|
+
* @docgenTable
|
|
66
|
+
* @tuple "["keyOf", T]"
|
|
67
|
+
* @helper keyOf(T)
|
|
68
|
+
* @example tuple
|
|
69
|
+
* const tupleKeyOf = type(["keyOf", {a:"string"}])
|
|
70
|
+
* @example helper
|
|
71
|
+
* const helperKeyOf = keyOf({a:"string"})
|
|
72
|
+
*/
|
|
24
73
|
export declare const keyOf: Ark["keyOf"];
|
|
74
|
+
/**
|
|
75
|
+
* @operator {@link instanceOf}
|
|
76
|
+
* @docgenTable
|
|
77
|
+
* @tuple ["instanceOf", T]
|
|
78
|
+
* @helper instanceOf(T)
|
|
79
|
+
* @example tuple
|
|
80
|
+
* const tupleInstanceOf = type(["instanceOf", Date])
|
|
81
|
+
* @example helper
|
|
82
|
+
* const helperInstanceOf = instanceOf(Date)
|
|
83
|
+
*/
|
|
25
84
|
export declare const instanceOf: Ark["instanceOf"];
|
|
85
|
+
/**
|
|
86
|
+
* @operator {@link valueOf | ===}
|
|
87
|
+
* @docgenTable
|
|
88
|
+
* @tuple ["===", T]
|
|
89
|
+
* @helper valueOf(T)
|
|
90
|
+
* @example tuple
|
|
91
|
+
* const tupleValueOf = type(["valueOf", {a:"string"}])
|
|
92
|
+
* @example helper
|
|
93
|
+
* const helperValueOf = valueOf({a:"string"})
|
|
94
|
+
*/
|
|
26
95
|
export declare const valueOf: Ark["valueOf"];
|
|
96
|
+
/**
|
|
97
|
+
* @operator {@link narrow | =>}
|
|
98
|
+
* @docgenTable
|
|
99
|
+
* @tuple ["type", "=>" , condition]
|
|
100
|
+
* @example tuple
|
|
101
|
+
* const narrow = type( ["number", "=>" , (n) => n % 2 === 0])
|
|
102
|
+
* @example
|
|
103
|
+
* const isEven = (x: unknown): x is number => x % 2 === 0
|
|
104
|
+
*/
|
|
27
105
|
export declare const narrow: Ark["narrow"];
|
|
106
|
+
/**
|
|
107
|
+
* @operator {@link morph | |>}
|
|
108
|
+
* @docgenTable
|
|
109
|
+
* @tuple [inputType, "|>", (data) => output]
|
|
110
|
+
* @helper morph(inputType, (data) => output)
|
|
111
|
+
* @example tuple
|
|
112
|
+
* const tupleMorph = type( ["string", "|>" , (data) => `morphed ${data}`])
|
|
113
|
+
* @example helper
|
|
114
|
+
* const helperMorph = morph("string", (data) => `morphed ${data}`)
|
|
115
|
+
*/
|
|
28
116
|
export declare const morph: Ark["morph"];
|
|
29
117
|
export type BinaryExpressionParser<$, operator extends "&" | "|"> = {
|
|
30
118
|
<l, r>(l: validateDefinition<l, $>, r: validateDefinition<r, $>): parseTupleExpression<[l, operator, r], $>;
|
|
@@ -1,31 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @docgenScope
|
|
3
|
+
* @docgenTable
|
|
4
|
+
*/
|
|
1
5
|
export declare const jsObjectsScope: import("./scope.js").Scope<[{
|
|
2
6
|
Function: (...args: any[]) => unknown;
|
|
3
|
-
Array: unknown[];
|
|
4
7
|
Date: Date;
|
|
5
8
|
Error: Error;
|
|
6
9
|
Map: Map<unknown, unknown>;
|
|
7
10
|
RegExp: RegExp;
|
|
8
11
|
Set: Set<unknown>;
|
|
9
|
-
Object: Record<string, unknown>;
|
|
10
|
-
String: String;
|
|
11
|
-
Number: Number;
|
|
12
|
-
Boolean: Boolean;
|
|
13
12
|
WeakMap: WeakMap<object, unknown>;
|
|
14
13
|
WeakSet: WeakSet<object>;
|
|
15
14
|
Promise: Promise<unknown>;
|
|
16
15
|
}, {}, false]>;
|
|
17
16
|
export declare const jsObjects: import("./scope.js").Space<{
|
|
18
17
|
Function: (...args: any[]) => unknown;
|
|
19
|
-
Array: unknown[];
|
|
20
18
|
Date: Date;
|
|
21
19
|
Error: Error;
|
|
22
20
|
Map: Map<unknown, unknown>;
|
|
23
21
|
RegExp: RegExp;
|
|
24
22
|
Set: Set<unknown>;
|
|
25
|
-
Object: Record<string, unknown>;
|
|
26
|
-
String: String;
|
|
27
|
-
Number: Number;
|
|
28
|
-
Boolean: Boolean;
|
|
29
23
|
WeakMap: WeakMap<object, unknown>;
|
|
30
24
|
WeakSet: WeakSet<object>;
|
|
31
25
|
Promise: Promise<unknown>;
|
|
@@ -1,3 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @keywords keywords: {"any": "any",
|
|
3
|
+
"bigint": "a bigint",
|
|
4
|
+
"boolean": "a boolean",
|
|
5
|
+
"false": "false",
|
|
6
|
+
"never": "never",
|
|
7
|
+
"null": "null",
|
|
8
|
+
"number": "a number",
|
|
9
|
+
"object": "an object",
|
|
10
|
+
"string": "a string",
|
|
11
|
+
"symbol": "a symbol",
|
|
12
|
+
"true": "true",
|
|
13
|
+
"unknown": "unknown",
|
|
14
|
+
"void": "void",
|
|
15
|
+
"undefined": "undefined"}
|
|
16
|
+
* @docgenScope
|
|
17
|
+
* @docgenTable
|
|
18
|
+
*/
|
|
1
19
|
export declare const tsKeywordsScope: import("./scope.js").Scope<[{
|
|
2
20
|
any: any;
|
|
3
21
|
bigint: bigint;
|
|
@@ -18,8 +18,9 @@ export type parseType<def, $> = [def] extends [validateDefinition<def, $>] ? Typ
|
|
|
18
18
|
type TypeRoot<t = unknown> = evaluate<{
|
|
19
19
|
[as]: t;
|
|
20
20
|
infer: asOut<t>;
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
inferIn: asIn<t>;
|
|
22
|
+
allows: (data: unknown) => data is asIn<t>;
|
|
23
|
+
assert: (data: unknown) => asOut<t>;
|
|
23
24
|
node: Node;
|
|
24
25
|
flat: TraversalNode;
|
|
25
26
|
qualifiedName: QualifiedTypeName;
|
|
@@ -35,6 +36,7 @@ export type TypeOptions = evaluate<{
|
|
|
35
36
|
export type TypeConfig = TypeOptions;
|
|
36
37
|
export declare const initializeType: (name: string, definition: unknown, config: TypeConfig, scope: Scope) => ((data: unknown) => CheckResult<unknown>) & {
|
|
37
38
|
infer: unknown;
|
|
39
|
+
inferIn: unknown;
|
|
38
40
|
allows: (data: unknown) => data is unknown;
|
|
39
41
|
assert: (data: unknown) => unknown;
|
|
40
42
|
node: Node;
|
|
@@ -1,3 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @keywords keywords: {
|
|
3
|
+
"alpha": "only letters",
|
|
4
|
+
"alphanumeric": "only letters and digits",
|
|
5
|
+
"lowercase": "only lowercase letters",
|
|
6
|
+
"uppercase": "only uppercase letters",
|
|
7
|
+
"creditCard": "a valid credit card number",
|
|
8
|
+
"email": "a valid email",
|
|
9
|
+
"uuid": "a valid UUID",
|
|
10
|
+
"parsedNumber": "a well-formed numeric string",
|
|
11
|
+
"parsedInteger": "a well-formed integer string",
|
|
12
|
+
"parsedDate": "a valid date",
|
|
13
|
+
"semver": "a valid semantic version",
|
|
14
|
+
"json": "a JSON-parsable string",
|
|
15
|
+
"integer": "an integer"
|
|
16
|
+
}
|
|
17
|
+
* @docgenScope
|
|
18
|
+
* @docgenTable
|
|
19
|
+
*/
|
|
1
20
|
export declare const validationScope: import("../scope.js").Scope<[{
|
|
2
21
|
alpha: string;
|
|
3
22
|
alphanumeric: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const asConst: <t>(t:
|
|
1
|
+
export declare const asConst: <t>(t: { [k in keyof t]: t[k] extends [] | Literalable ? t[k] : t[k] extends infer T ? { [k_1 in keyof T]: t[k][k_1] extends [] | Literalable ? t[k][k_1] : t[k][k_1] extends infer T_1 ? { [k_2 in keyof T_1]: t[k][k_1][k_2] extends [] | Literalable ? t[k][k_1][k_2] : t[k][k_1][k_2] extends infer T_2 ? { [k_3 in keyof T_2]: t[k][k_1][k_2][k_3] extends [] | Literalable ? t[k][k_1][k_2][k_3] : t[k][k_1][k_2][k_3] extends infer T_3 ? { [k_4 in keyof T_3]: t[k][k_1][k_2][k_3][k_4] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4] : t[k][k_1][k_2][k_3][k_4] extends infer T_4 ? { [k_5 in keyof T_4]: t[k][k_1][k_2][k_3][k_4][k_5] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5] : t[k][k_1][k_2][k_3][k_4][k_5] extends infer T_5 ? { [k_6 in keyof T_5]: t[k][k_1][k_2][k_3][k_4][k_5][k_6] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6] : t[k][k_1][k_2][k_3][k_4][k_5][k_6] extends infer T_6 ? { [k_7 in keyof T_6]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7] : t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7] extends infer T_7 ? { [k_8 in keyof T_7]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8] : t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8] extends infer T_8 ? { [k_9 in keyof T_8]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9] : t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9] extends infer T_9 ? { [k_10 in keyof T_9]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9][k_10] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9][k_10] : any; } : never; } : never; } : never; } : never; } : never; } : never; } : never; } : never; } : never; } : never; }) => { [k in keyof t]: t[k] extends [] | Literalable ? t[k] : t[k] extends infer T ? { [k_1 in keyof T]: t[k][k_1] extends [] | Literalable ? t[k][k_1] : t[k][k_1] extends infer T_1 ? { [k_2 in keyof T_1]: t[k][k_1][k_2] extends [] | Literalable ? t[k][k_1][k_2] : t[k][k_1][k_2] extends infer T_2 ? { [k_3 in keyof T_2]: t[k][k_1][k_2][k_3] extends [] | Literalable ? t[k][k_1][k_2][k_3] : t[k][k_1][k_2][k_3] extends infer T_3 ? { [k_4 in keyof T_3]: t[k][k_1][k_2][k_3][k_4] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4] : t[k][k_1][k_2][k_3][k_4] extends infer T_4 ? { [k_5 in keyof T_4]: t[k][k_1][k_2][k_3][k_4][k_5] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5] : t[k][k_1][k_2][k_3][k_4][k_5] extends infer T_5 ? { [k_6 in keyof T_5]: t[k][k_1][k_2][k_3][k_4][k_5][k_6] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6] : t[k][k_1][k_2][k_3][k_4][k_5][k_6] extends infer T_6 ? { [k_7 in keyof T_6]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7] : t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7] extends infer T_7 ? { [k_8 in keyof T_7]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8] : t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8] extends infer T_8 ? { [k_9 in keyof T_8]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9] : t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9] extends infer T_9 ? { [k_10 in keyof T_9]: t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9][k_10] extends [] | Literalable ? t[k][k_1][k_2][k_3][k_4][k_5][k_6][k_7][k_8][k_9][k_10] : any; } : never; } : never; } : never; } : never; } : never; } : never; } : never; } : never; } : never; } : never; };
|
|
2
2
|
export type asConst<t> = castWithExclusion<t, asConstRecurse<t>, []>;
|
|
3
3
|
type asConstRecurse<t> = {
|
|
4
4
|
[k in keyof t]: t[k] extends Literalable | [] ? t[k] : asConstRecurse<t[k]>;
|
|
@@ -88,7 +88,7 @@ export type requiredKeyOf<o> = {
|
|
|
88
88
|
export type optionalKeyOf<o> = Exclude<keyof o, requiredKeyOf<o>>;
|
|
89
89
|
/** Type equivalent of ?? */
|
|
90
90
|
export type coalesce<t, fallback> = t extends {} ? t : fallback;
|
|
91
|
-
export type error<message extends string = string> =
|
|
91
|
+
export type error<message extends string = string> = `!${message}`;
|
|
92
92
|
export type castOnError<t, to> = isTopType<t> extends true ? t : t extends never ? t : t extends error ? to : t;
|
|
93
93
|
export type tryCatch<t, onValid> = isAny<t> extends true ? onValid : t extends never ? onValid : t extends error ? t : onValid;
|
|
94
94
|
export type RegexLiteral<expression extends string = string> = `/${expression}/`;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "arktype",
|
|
3
|
-
"description": "
|
|
4
|
-
"version": "1.0.
|
|
3
|
+
"description": "TypeScript's 1:1 validator, optimized from editor to runtime",
|
|
4
|
+
"version": "1.0.11-alpha",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "David Blass",
|
|
7
7
|
"email": "david@arktype.io",
|
|
@@ -31,34 +31,34 @@
|
|
|
31
31
|
],
|
|
32
32
|
"packageManager": "pnpm@7.27.0",
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@changesets/cli": "2.26.0",
|
|
35
34
|
"@changesets/changelog-github": "0.4.8",
|
|
35
|
+
"@changesets/cli": "2.26.1",
|
|
36
36
|
"@swc/cli": "0.1.62",
|
|
37
|
-
"@swc/core": "1.3.
|
|
37
|
+
"@swc/core": "1.3.42",
|
|
38
38
|
"@types/mocha": "10.0.1",
|
|
39
|
-
"@types/node": "18.
|
|
40
|
-
"@typescript-eslint/eslint-plugin": "5.
|
|
41
|
-
"@typescript-eslint/parser": "5.
|
|
39
|
+
"@types/node": "18.15.5",
|
|
40
|
+
"@typescript-eslint/eslint-plugin": "5.56.0",
|
|
41
|
+
"@typescript-eslint/parser": "5.56.0",
|
|
42
42
|
"c8": "7.13.0",
|
|
43
|
-
"eslint": "8.
|
|
44
|
-
"eslint-config-prettier": "8.
|
|
45
|
-
"eslint-define-config": "1.
|
|
43
|
+
"eslint": "8.36.0",
|
|
44
|
+
"eslint-config-prettier": "8.8.0",
|
|
45
|
+
"eslint-define-config": "1.17.0",
|
|
46
46
|
"eslint-import-resolver-typescript": "3.5.3",
|
|
47
47
|
"eslint-plugin-import": "2.27.5",
|
|
48
48
|
"eslint-plugin-only-warn": "1.1.0",
|
|
49
49
|
"eslint-plugin-prefer-arrow": "1.2.3",
|
|
50
|
-
"eslint-plugin-unicorn": "
|
|
51
|
-
"fast-check": "3.
|
|
50
|
+
"eslint-plugin-unicorn": "46.0.0",
|
|
51
|
+
"fast-check": "3.7.1",
|
|
52
52
|
"get-current-line": "6.6.0",
|
|
53
53
|
"husky": "8.0.3",
|
|
54
54
|
"mocha": "10.2.0",
|
|
55
|
-
"prettier": "2.8.
|
|
55
|
+
"prettier": "2.8.6",
|
|
56
56
|
"prettier-plugin-jsdoc": "0.4.2",
|
|
57
57
|
"pretty-quick": "3.1.3",
|
|
58
|
-
"ts-morph": "
|
|
58
|
+
"ts-morph": "18.0.0",
|
|
59
59
|
"ts-node": "10.9.1",
|
|
60
|
-
"typescript": "5.0.
|
|
61
|
-
"zod": "3.
|
|
60
|
+
"typescript": "5.0.3",
|
|
61
|
+
"zod": "3.21.4"
|
|
62
62
|
},
|
|
63
63
|
"c8": {
|
|
64
64
|
"checkCoverage": true,
|
|
@@ -99,11 +99,10 @@
|
|
|
99
99
|
"docgen": "ts-node ./dev/scripts/docgen.ts",
|
|
100
100
|
"test": "ts-node ./dev/attest/cli.ts --coverage --cmd mocha",
|
|
101
101
|
"tnt": "ts-node ./dev/attest/cli.ts --coverage --skipTypes --cmd mocha",
|
|
102
|
-
"testRepo": " pnpm testBuild && pnpm testTsVersions && pnpm testAttest
|
|
102
|
+
"testRepo": " pnpm testBuild && pnpm testTsVersions && pnpm testAttest",
|
|
103
103
|
"testBuild": "ts-node ./dev/scripts/testBuild.ts",
|
|
104
104
|
"testAttest": "ts-node ./dev/scripts/testAttest.ts",
|
|
105
105
|
"testTsVersions": "ts-node ./dev/scripts/testTsVersions.ts",
|
|
106
|
-
"testDeno": "deno test -c ./dev/configs/deno.jsonc --no-check --allow-all",
|
|
107
106
|
"bench": "ts-node ./dev/attest/cli.ts bench --benchmarksPath ./test/benchmarks.json",
|
|
108
107
|
"lint": "eslint --max-warnings=0 .",
|
|
109
108
|
"format": "prettier --write --ignore-path ./dev/configs/.prettierignore .",
|