@sinclair/typebox 0.24.50 → 0.24.52
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/compiler/compiler.d.ts +25 -28
- package/compiler/compiler.js +408 -409
- package/compiler/index.d.ts +2 -2
- package/compiler/index.js +47 -47
- package/conditional/conditional.d.ts +17 -17
- package/conditional/conditional.js +91 -91
- package/conditional/index.d.ts +2 -2
- package/conditional/index.js +45 -45
- package/conditional/structural.d.ts +11 -11
- package/conditional/structural.js +657 -657
- package/errors/errors.d.ts +60 -60
- package/errors/errors.js +398 -398
- package/errors/index.d.ts +1 -1
- package/errors/index.js +44 -44
- package/format/format.d.ts +12 -12
- package/format/format.js +55 -55
- package/format/index.d.ts +1 -1
- package/format/index.js +44 -44
- package/guard/guard.d.ts +56 -56
- package/guard/guard.js +351 -351
- package/guard/index.d.ts +1 -1
- package/guard/index.js +44 -44
- package/license +22 -22
- package/package.json +43 -40
- package/readme.md +1152 -1152
- package/typebox.d.ts +408 -408
- package/typebox.js +383 -383
- package/value/cast.d.ts +26 -26
- package/value/cast.js +364 -364
- package/value/check.d.ts +8 -8
- package/value/check.js +331 -331
- package/value/clone.d.ts +3 -3
- package/value/clone.js +65 -65
- package/value/create.d.ts +14 -14
- package/value/create.js +357 -357
- package/value/delta.d.ts +22 -22
- package/value/delta.js +168 -168
- package/value/equal.d.ts +3 -3
- package/value/equal.js +74 -74
- package/value/index.d.ts +3 -3
- package/value/index.js +48 -48
- package/value/is.d.ts +10 -10
- package/value/is.js +49 -49
- package/value/pointer.d.ts +24 -24
- package/value/pointer.js +142 -142
- package/value/value.d.ts +31 -31
- package/value/value.js +81 -81
package/errors/errors.d.ts
CHANGED
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
import * as Types from '../typebox';
|
|
2
|
-
export declare enum ValueErrorType {
|
|
3
|
-
Array = 0,
|
|
4
|
-
ArrayMinItems = 1,
|
|
5
|
-
ArrayMaxItems = 2,
|
|
6
|
-
ArrayUniqueItems = 3,
|
|
7
|
-
Boolean = 4,
|
|
8
|
-
Function = 5,
|
|
9
|
-
Integer = 6,
|
|
10
|
-
IntegerMultipleOf = 7,
|
|
11
|
-
IntegerExclusiveMinimum = 8,
|
|
12
|
-
IntegerExclusiveMaximum = 9,
|
|
13
|
-
IntegerMinimum = 10,
|
|
14
|
-
IntegerMaximum = 11,
|
|
15
|
-
Literal = 12,
|
|
16
|
-
Never = 13,
|
|
17
|
-
Null = 14,
|
|
18
|
-
Number = 15,
|
|
19
|
-
NumberMultipleOf = 16,
|
|
20
|
-
NumberExclusiveMinimum = 17,
|
|
21
|
-
NumberExclusiveMaximum = 18,
|
|
22
|
-
NumberMinumum = 19,
|
|
23
|
-
NumberMaximum = 20,
|
|
24
|
-
Object = 21,
|
|
25
|
-
ObjectMinProperties = 22,
|
|
26
|
-
ObjectMaxProperties = 23,
|
|
27
|
-
ObjectAdditionalProperties = 24,
|
|
28
|
-
ObjectRequiredProperties = 25,
|
|
29
|
-
Promise = 26,
|
|
30
|
-
RecordKeyNumeric = 27,
|
|
31
|
-
RecordKeyString = 28,
|
|
32
|
-
String = 29,
|
|
33
|
-
StringMinLength = 30,
|
|
34
|
-
StringMaxLength = 31,
|
|
35
|
-
StringPattern = 32,
|
|
36
|
-
StringFormatUnknown = 33,
|
|
37
|
-
StringFormat = 34,
|
|
38
|
-
TupleZeroLength = 35,
|
|
39
|
-
TupleLength = 36,
|
|
40
|
-
Undefined = 37,
|
|
41
|
-
Union = 38,
|
|
42
|
-
Uint8Array = 39,
|
|
43
|
-
Uint8ArrayMinByteLength = 40,
|
|
44
|
-
Uint8ArrayMaxByteLength = 41,
|
|
45
|
-
Void = 42
|
|
46
|
-
}
|
|
47
|
-
export interface ValueError {
|
|
48
|
-
type: ValueErrorType;
|
|
49
|
-
schema: Types.TSchema;
|
|
50
|
-
path: string;
|
|
51
|
-
value: unknown;
|
|
52
|
-
message: string;
|
|
53
|
-
}
|
|
54
|
-
export declare class ValueErrorsUnknownTypeError extends Error {
|
|
55
|
-
readonly schema: Types.TSchema;
|
|
56
|
-
constructor(schema: Types.TSchema);
|
|
57
|
-
}
|
|
58
|
-
export declare namespace ValueErrors {
|
|
59
|
-
function Errors<T extends Types.TSchema>(schema: T, references: Types.TSchema[], value: any): IterableIterator<ValueError>;
|
|
60
|
-
}
|
|
1
|
+
import * as Types from '../typebox';
|
|
2
|
+
export declare enum ValueErrorType {
|
|
3
|
+
Array = 0,
|
|
4
|
+
ArrayMinItems = 1,
|
|
5
|
+
ArrayMaxItems = 2,
|
|
6
|
+
ArrayUniqueItems = 3,
|
|
7
|
+
Boolean = 4,
|
|
8
|
+
Function = 5,
|
|
9
|
+
Integer = 6,
|
|
10
|
+
IntegerMultipleOf = 7,
|
|
11
|
+
IntegerExclusiveMinimum = 8,
|
|
12
|
+
IntegerExclusiveMaximum = 9,
|
|
13
|
+
IntegerMinimum = 10,
|
|
14
|
+
IntegerMaximum = 11,
|
|
15
|
+
Literal = 12,
|
|
16
|
+
Never = 13,
|
|
17
|
+
Null = 14,
|
|
18
|
+
Number = 15,
|
|
19
|
+
NumberMultipleOf = 16,
|
|
20
|
+
NumberExclusiveMinimum = 17,
|
|
21
|
+
NumberExclusiveMaximum = 18,
|
|
22
|
+
NumberMinumum = 19,
|
|
23
|
+
NumberMaximum = 20,
|
|
24
|
+
Object = 21,
|
|
25
|
+
ObjectMinProperties = 22,
|
|
26
|
+
ObjectMaxProperties = 23,
|
|
27
|
+
ObjectAdditionalProperties = 24,
|
|
28
|
+
ObjectRequiredProperties = 25,
|
|
29
|
+
Promise = 26,
|
|
30
|
+
RecordKeyNumeric = 27,
|
|
31
|
+
RecordKeyString = 28,
|
|
32
|
+
String = 29,
|
|
33
|
+
StringMinLength = 30,
|
|
34
|
+
StringMaxLength = 31,
|
|
35
|
+
StringPattern = 32,
|
|
36
|
+
StringFormatUnknown = 33,
|
|
37
|
+
StringFormat = 34,
|
|
38
|
+
TupleZeroLength = 35,
|
|
39
|
+
TupleLength = 36,
|
|
40
|
+
Undefined = 37,
|
|
41
|
+
Union = 38,
|
|
42
|
+
Uint8Array = 39,
|
|
43
|
+
Uint8ArrayMinByteLength = 40,
|
|
44
|
+
Uint8ArrayMaxByteLength = 41,
|
|
45
|
+
Void = 42
|
|
46
|
+
}
|
|
47
|
+
export interface ValueError {
|
|
48
|
+
type: ValueErrorType;
|
|
49
|
+
schema: Types.TSchema;
|
|
50
|
+
path: string;
|
|
51
|
+
value: unknown;
|
|
52
|
+
message: string;
|
|
53
|
+
}
|
|
54
|
+
export declare class ValueErrorsUnknownTypeError extends Error {
|
|
55
|
+
readonly schema: Types.TSchema;
|
|
56
|
+
constructor(schema: Types.TSchema);
|
|
57
|
+
}
|
|
58
|
+
export declare namespace ValueErrors {
|
|
59
|
+
function Errors<T extends Types.TSchema>(schema: T, references: Types.TSchema[], value: any): IterableIterator<ValueError>;
|
|
60
|
+
}
|