@layerzerolabs/typescript-utils 0.2.46 → 0.2.47
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/.turbo/turbo-build.log +110 -110
- package/.turbo/turbo-lint.log +1 -1
- package/dist/{ZDGUYQPS.cjs → B4TXK443.cjs} +2 -2
- package/dist/B4TXK443.cjs.map +1 -0
- package/dist/{ENRZFLLD.js → J7BAXUWJ.js} +2 -2
- package/dist/J7BAXUWJ.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/viem.cjs +1 -1
- package/dist/viem.d.ts +1 -1
- package/dist/viem.js +1 -1
- package/package.json +3 -3
- package/src/viem.ts +1 -1
- package/dist/ENRZFLLD.js.map +0 -1
- package/dist/ZDGUYQPS.cjs.map +0 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -11,168 +11,168 @@
|
|
|
11
11
|
[34mCLI[39m Cleaning output folder
|
|
12
12
|
[34mCJS[39m Build start
|
|
13
13
|
[34mESM[39m Build start
|
|
14
|
+
Entry module "dist/EUBM3LSR.cjs" is using named and default exports together. Consumers of your bundle will have to use `chunk.default` to access the default export, which may not be what you want. Use `output.exports: "named"` to disable this warning.
|
|
14
15
|
"default" is imported from external module "path" but never used in "dist/6AHA7PAZ.js".
|
|
15
16
|
"fileURLToPath" is imported from external module "url" but never used in "dist/6AHA7PAZ.js".
|
|
16
|
-
|
|
17
|
+
[32mCJS[39m [1mdist/tuples.cjs [22m[32m141.00 B[39m
|
|
18
|
+
[32mCJS[39m [1mdist/valueOf.cjs [22m[32m143.00 B[39m
|
|
19
|
+
[32mCJS[39m [1mdist/viem.cjs [22m[32m137.00 B[39m
|
|
20
|
+
[32mCJS[39m [1mdist/2MZ52QXI.cjs [22m[32m188.00 B[39m
|
|
21
|
+
[32mCJS[39m [1mdist/B4TXK443.cjs [22m[32m185.00 B[39m
|
|
22
|
+
[32mCJS[39m [1mdist/withRequired.cjs [22m[32m153.00 B[39m
|
|
23
|
+
[32mCJS[39m [1mdist/4W25K7RR.cjs [22m[32m193.00 B[39m
|
|
24
|
+
[32mCJS[39m [1mdist/lastOf.cjs [22m[32m141.00 B[39m
|
|
25
|
+
[32mCJS[39m [1mdist/2OSBYVBM.cjs [22m[32m187.00 B[39m
|
|
26
|
+
[32mCJS[39m [1mdist/maybeUndefined.cjs [22m[32m157.00 B[39m
|
|
27
|
+
[32mCJS[39m [1mdist/7RPBI4LQ.cjs [22m[32m195.00 B[39m
|
|
28
|
+
[32mCJS[39m [1mdist/merge.cjs [22m[32m139.00 B[39m
|
|
29
|
+
[32mCJS[39m [1mdist/AKBGASRF.cjs [22m[32m186.00 B[39m
|
|
30
|
+
[32mCJS[39m [1mdist/EUBM3LSR.cjs [22m[32m42.53 KB[39m
|
|
31
|
+
[32mCJS[39m [1mdist/NKWLAYNJ.cjs [22m[32m189.00 B[39m
|
|
32
|
+
[32mCJS[39m [1mdist/methodOf.cjs [22m[32m145.00 B[39m
|
|
33
|
+
[32mCJS[39m [1mdist/Q35ZNXMT.cjs [22m[32m192.00 B[39m
|
|
34
|
+
[32mCJS[39m [1mdist/removeNever.cjs [22m[32m151.00 B[39m
|
|
35
|
+
[32mCJS[39m [1mdist/strings.test-d.cjs [22m[32m904.00 B[39m
|
|
36
|
+
[32mCJS[39m [1mdist/strings.cjs [22m[32m143.00 B[39m
|
|
37
|
+
[32mCJS[39m [1mdist/advancedRecord.cjs [22m[32m157.00 B[39m
|
|
38
|
+
[32mCJS[39m [1mdist/K3FZ3EZT.cjs [22m[32m188.00 B[39m
|
|
39
|
+
[32mCJS[39m [1mdist/C7GMKBCN.cjs [22m[32m195.00 B[39m
|
|
40
|
+
[32mCJS[39m [1mdist/asyncify.cjs [22m[32m145.00 B[39m
|
|
41
|
+
[32mCJS[39m [1mdist/WPET3HPL.cjs [22m[32m189.00 B[39m
|
|
42
|
+
[32mCJS[39m [1mdist/branded.cjs [22m[32m143.00 B[39m
|
|
43
|
+
[32mCJS[39m [1mdist/2SJJDCZI.cjs [22m[32m188.00 B[39m
|
|
44
|
+
[32mCJS[39m [1mdist/constructor.cjs [22m[32m151.00 B[39m
|
|
45
|
+
[32mCJS[39m [1mdist/deep.cjs [22m[32m137.00 B[39m
|
|
46
|
+
[32mCJS[39m [1mdist/53OHF4EH.cjs [22m[32m192.00 B[39m
|
|
47
|
+
[32mCJS[39m [1mdist/MLSONTXK.cjs [22m[32m185.00 B[39m
|
|
48
|
+
[32mCJS[39m [1mdist/index.cjs [22m[32m639.00 B[39m
|
|
49
|
+
[32mCJS[39m [1mdist/disallowedAny.cjs [22m[32m155.00 B[39m
|
|
50
|
+
[32mCJS[39m [1mdist/identity.cjs [22m[32m145.00 B[39m
|
|
51
|
+
[32mCJS[39m [1mdist/TVCGTTL5.cjs [22m[32m189.00 B[39m
|
|
52
|
+
[32mCJS[39m [1mdist/24WEKBY3.cjs [22m[32m2.10 KB[39m
|
|
53
|
+
[32mCJS[39m [1mdist/574X5FJM.cjs [22m[32m194.00 B[39m
|
|
54
|
+
[32mCJS[39m [1mdist/KQUDWU4T.cjs [22m[32m187.00 B[39m
|
|
55
|
+
[32mCJS[39m [1mdist/deep.test-d.cjs [22m[32m580.00 B[39m
|
|
56
|
+
[32mCJS[39m [1mdist/7BSTQVJO.cjs [22m[32m301.19 KB[39m
|
|
57
|
+
[32mCJS[39m [1mdist/tuples.cjs.map [22m[32m71.00 B[39m
|
|
58
|
+
[32mCJS[39m [1mdist/viem.cjs.map [22m[32m69.00 B[39m
|
|
59
|
+
[32mCJS[39m [1mdist/valueOf.cjs.map [22m[32m72.00 B[39m
|
|
60
|
+
[32mCJS[39m [1mdist/2OSBYVBM.cjs.map [22m[32m659.00 B[39m
|
|
61
|
+
[32mCJS[39m [1mdist/lastOf.cjs.map [22m[32m71.00 B[39m
|
|
62
|
+
[32mCJS[39m [1mdist/4W25K7RR.cjs.map [22m[32m299.00 B[39m
|
|
63
|
+
[32mCJS[39m [1mdist/7RPBI4LQ.cjs.map [22m[32m642.00 B[39m
|
|
64
|
+
[32mCJS[39m [1mdist/maybeUndefined.cjs.map [22m[32m79.00 B[39m
|
|
65
|
+
[32mCJS[39m [1mdist/merge.cjs.map [22m[32m70.00 B[39m
|
|
66
|
+
[32mCJS[39m [1mdist/AKBGASRF.cjs.map [22m[32m469.00 B[39m
|
|
67
|
+
[32mCJS[39m [1mdist/NKWLAYNJ.cjs.map [22m[32m399.00 B[39m
|
|
68
|
+
[32mCJS[39m [1mdist/methodOf.cjs.map [22m[32m73.00 B[39m
|
|
69
|
+
[32mCJS[39m [1mdist/Q35ZNXMT.cjs.map [22m[32m252.00 B[39m
|
|
70
|
+
[32mCJS[39m [1mdist/removeNever.cjs.map [22m[32m76.00 B[39m
|
|
71
|
+
[32mCJS[39m [1mdist/EUBM3LSR.cjs.map [22m[32m100.19 KB[39m
|
|
72
|
+
[32mCJS[39m [1mdist/strings.test-d.cjs.map [22m[32m1.70 KB[39m
|
|
73
|
+
[32mCJS[39m [1mdist/advancedRecord.cjs.map [22m[32m79.00 B[39m
|
|
74
|
+
[32mCJS[39m [1mdist/strings.cjs.map [22m[32m72.00 B[39m
|
|
75
|
+
[32mCJS[39m [1mdist/K3FZ3EZT.cjs.map [22m[32m1.42 KB[39m
|
|
76
|
+
[32mCJS[39m [1mdist/asyncify.cjs.map [22m[32m73.00 B[39m
|
|
77
|
+
[32mCJS[39m [1mdist/C7GMKBCN.cjs.map [22m[32m906.00 B[39m
|
|
78
|
+
[32mCJS[39m [1mdist/branded.cjs.map [22m[32m72.00 B[39m
|
|
79
|
+
[32mCJS[39m [1mdist/WPET3HPL.cjs.map [22m[32m341.00 B[39m
|
|
80
|
+
[32mCJS[39m [1mdist/2SJJDCZI.cjs.map [22m[32m719.00 B[39m
|
|
81
|
+
[32mCJS[39m [1mdist/constructor.cjs.map [22m[32m76.00 B[39m
|
|
82
|
+
[32mCJS[39m [1mdist/53OHF4EH.cjs.map [22m[32m214.00 B[39m
|
|
83
|
+
[32mCJS[39m [1mdist/deep.cjs.map [22m[32m69.00 B[39m
|
|
84
|
+
[32mCJS[39m [1mdist/MLSONTXK.cjs.map [22m[32m780.00 B[39m
|
|
85
|
+
[32mCJS[39m [1mdist/disallowedAny.cjs.map [22m[32m78.00 B[39m
|
|
86
|
+
[32mCJS[39m [1mdist/index.cjs.map [22m[32m665.00 B[39m
|
|
87
|
+
[32mCJS[39m [1mdist/identity.cjs.map [22m[32m73.00 B[39m
|
|
88
|
+
[32mCJS[39m [1mdist/TVCGTTL5.cjs.map [22m[32m265.00 B[39m
|
|
89
|
+
[32mCJS[39m [1mdist/24WEKBY3.cjs.map [22m[32m923.00 B[39m
|
|
90
|
+
[32mCJS[39m [1mdist/574X5FJM.cjs.map [22m[32m390.00 B[39m
|
|
91
|
+
[32mCJS[39m [1mdist/KQUDWU4T.cjs.map [22m[32m2.68 KB[39m
|
|
92
|
+
[32mCJS[39m [1mdist/deep.test-d.cjs.map [22m[32m1.47 KB[39m
|
|
93
|
+
[32mCJS[39m [1mdist/2MZ52QXI.cjs.map [22m[32m538.00 B[39m
|
|
94
|
+
[32mCJS[39m [1mdist/B4TXK443.cjs.map [22m[32m8.26 KB[39m
|
|
95
|
+
[32mCJS[39m [1mdist/withRequired.cjs.map [22m[32m77.00 B[39m
|
|
96
|
+
[32mCJS[39m [1mdist/7BSTQVJO.cjs.map [22m[32m762.74 KB[39m
|
|
97
|
+
[32mCJS[39m ⚡️ Build success in 1200ms
|
|
17
98
|
[32mESM[39m [1mdist/tuples.js [22m[32m117.00 B[39m
|
|
18
|
-
[32mESM[39m [1mdist/valueOf.js [22m[32m119.00 B[39m
|
|
19
|
-
[32mESM[39m [1mdist/viem.js [22m[32m113.00 B[39m
|
|
20
99
|
[32mESM[39m [1mdist/withRequired.js [22m[32m129.00 B[39m
|
|
100
|
+
[32mESM[39m [1mdist/viem.js [22m[32m113.00 B[39m
|
|
101
|
+
[32mESM[39m [1mdist/valueOf.js [22m[32m119.00 B[39m
|
|
21
102
|
[32mESM[39m [1mdist/index.js [22m[32m558.00 B[39m
|
|
22
103
|
[32mESM[39m [1mdist/EM7SXG4B.js [22m[32m157.00 B[39m
|
|
23
104
|
[32mESM[39m [1mdist/TQNP6GIE.js [22m[32m158.00 B[39m
|
|
24
|
-
[32mESM[39m [1mdist/
|
|
105
|
+
[32mESM[39m [1mdist/J7BAXUWJ.js [22m[32m155.00 B[39m
|
|
25
106
|
[32mESM[39m [1mdist/62TVLGZP.js [22m[32m163.00 B[39m
|
|
26
107
|
[32mESM[39m [1mdist/lastOf.js [22m[32m117.00 B[39m
|
|
27
|
-
[32mESM[39m [1mdist/KZQATXOW.js [22m[32m157.00 B[39m
|
|
28
108
|
[32mESM[39m [1mdist/maybeUndefined.js [22m[32m133.00 B[39m
|
|
109
|
+
[32mESM[39m [1mdist/KZQATXOW.js [22m[32m157.00 B[39m
|
|
29
110
|
[32mESM[39m [1mdist/Q6UBIYTZ.js [22m[32m165.00 B[39m
|
|
30
111
|
[32mESM[39m [1mdist/merge.js [22m[32m115.00 B[39m
|
|
31
|
-
[32mESM[39m [1mdist/DDDCRYAA.js [22m[32m156.00 B[39m
|
|
32
|
-
[32mESM[39m [1mdist/KEJFF7VD.js [22m[32m159.00 B[39m
|
|
33
112
|
[32mESM[39m [1mdist/methodOf.js [22m[32m121.00 B[39m
|
|
113
|
+
[32mESM[39m [1mdist/DDDCRYAA.js [22m[32m156.00 B[39m
|
|
34
114
|
[32mESM[39m [1mdist/removeNever.js [22m[32m127.00 B[39m
|
|
35
115
|
[32mESM[39m [1mdist/I5NXBMAF.js [22m[32m162.00 B[39m
|
|
36
116
|
[32mESM[39m [1mdist/strings.test-d.js [22m[32m745.00 B[39m
|
|
37
|
-
[32mESM[39m [1mdist/
|
|
117
|
+
[32mESM[39m [1mdist/KEJFF7VD.js [22m[32m159.00 B[39m
|
|
38
118
|
[32mESM[39m [1mdist/B5GSIBEU.js [22m[32m158.00 B[39m
|
|
39
119
|
[32mESM[39m [1mdist/advancedRecord.js [22m[32m133.00 B[39m
|
|
120
|
+
[32mESM[39m [1mdist/strings.js [22m[32m119.00 B[39m
|
|
40
121
|
[32mESM[39m [1mdist/CFTTK4D6.js [22m[32m165.00 B[39m
|
|
41
|
-
[32mESM[39m [1mdist/GGKJNPTT.js [22m[32m42.15 KB[39m
|
|
42
122
|
[32mESM[39m [1mdist/asyncify.js [22m[32m121.00 B[39m
|
|
123
|
+
[32mESM[39m [1mdist/GGKJNPTT.js [22m[32m42.15 KB[39m
|
|
43
124
|
[32mESM[39m [1mdist/branded.js [22m[32m119.00 B[39m
|
|
44
125
|
[32mESM[39m [1mdist/TP4DJK6G.js [22m[32m159.00 B[39m
|
|
45
126
|
[32mESM[39m [1mdist/6IUBP3YE.js [22m[32m158.00 B[39m
|
|
46
|
-
[32mESM[39m [1mdist/
|
|
127
|
+
[32mESM[39m [1mdist/deep.js [22m[32m113.00 B[39m
|
|
47
128
|
[32mESM[39m [1mdist/X6GYSLZB.js [22m[32m162.00 B[39m
|
|
129
|
+
[32mESM[39m [1mdist/constructor.js [22m[32m127.00 B[39m
|
|
48
130
|
[32mESM[39m [1mdist/deep.test-d.js [22m[32m491.00 B[39m
|
|
49
|
-
[32mESM[39m [1mdist/deep.js [22m[32m113.00 B[39m
|
|
50
|
-
[32mESM[39m [1mdist/FQ2L5NQU.js [22m[32m155.00 B[39m
|
|
51
131
|
[32mESM[39m [1mdist/disallowedAny.js [22m[32m131.00 B[39m
|
|
132
|
+
[32mESM[39m [1mdist/FQ2L5NQU.js [22m[32m155.00 B[39m
|
|
52
133
|
[32mESM[39m [1mdist/V353KAGF.js [22m[32m164.00 B[39m
|
|
53
134
|
[32mESM[39m [1mdist/identity.js [22m[32m121.00 B[39m
|
|
54
135
|
[32mESM[39m [1mdist/P3JODCMF.js [22m[32m159.00 B[39m
|
|
55
136
|
[32mESM[39m [1mdist/6AHA7PAZ.js [22m[32m1.87 KB[39m
|
|
56
137
|
[32mESM[39m [1mdist/CI7BVOAG.js [22m[32m295.28 KB[39m
|
|
57
138
|
[32mESM[39m [1mdist/tuples.js.map [22m[32m70.00 B[39m
|
|
58
|
-
[32mESM[39m [1mdist/viem.js.map [22m[32m68.00 B[39m
|
|
59
139
|
[32mESM[39m [1mdist/withRequired.js.map [22m[32m76.00 B[39m
|
|
60
|
-
[32mESM[39m [1mdist/
|
|
61
|
-
[32mESM[39m [1mdist/
|
|
62
|
-
[32mESM[39m [1mdist/EM7SXG4B.js.map [22m[32m2.66 KB[39m
|
|
63
|
-
[32mESM[39m [1mdist/ENRZFLLD.js.map [22m[32m8.23 KB[39m
|
|
140
|
+
[32mESM[39m [1mdist/viem.js.map [22m[32m68.00 B[39m
|
|
141
|
+
[32mESM[39m [1mdist/valueOf.js.map [22m[32m71.00 B[39m
|
|
64
142
|
[32mESM[39m [1mdist/62TVLGZP.js.map [22m[32m278.00 B[39m
|
|
65
|
-
[32mESM[39m [1mdist/
|
|
143
|
+
[32mESM[39m [1mdist/index.js.map [22m[32m644.00 B[39m
|
|
66
144
|
[32mESM[39m [1mdist/lastOf.js.map [22m[32m70.00 B[39m
|
|
67
145
|
[32mESM[39m [1mdist/maybeUndefined.js.map [22m[32m78.00 B[39m
|
|
146
|
+
[32mESM[39m [1mdist/EM7SXG4B.js.map [22m[32m2.66 KB[39m
|
|
147
|
+
[32mESM[39m [1mdist/KZQATXOW.js.map [22m[32m638.00 B[39m
|
|
68
148
|
[32mESM[39m [1mdist/Q6UBIYTZ.js.map [22m[32m621.00 B[39m
|
|
69
149
|
[32mESM[39m [1mdist/merge.js.map [22m[32m69.00 B[39m
|
|
70
|
-
[32mESM[39m [1mdist/DDDCRYAA.js.map [22m[32m448.00 B[39m
|
|
71
|
-
[32mESM[39m [1mdist/KEJFF7VD.js.map [22m[32m378.00 B[39m
|
|
72
|
-
[32mESM[39m [1mdist/methodOf.js.map [22m[32m72.00 B[39m
|
|
73
150
|
[32mESM[39m [1mdist/removeNever.js.map [22m[32m75.00 B[39m
|
|
151
|
+
[32mESM[39m [1mdist/DDDCRYAA.js.map [22m[32m448.00 B[39m
|
|
74
152
|
[32mESM[39m [1mdist/I5NXBMAF.js.map [22m[32m231.00 B[39m
|
|
75
|
-
[32mESM[39m [1mdist/strings.js.map [22m[32m71.00 B[39m
|
|
76
153
|
[32mESM[39m [1mdist/strings.test-d.js.map [22m[32m1.68 KB[39m
|
|
77
|
-
[32mESM[39m [1mdist/
|
|
154
|
+
[32mESM[39m [1mdist/methodOf.js.map [22m[32m72.00 B[39m
|
|
155
|
+
[32mESM[39m [1mdist/KEJFF7VD.js.map [22m[32m378.00 B[39m
|
|
78
156
|
[32mESM[39m [1mdist/advancedRecord.js.map [22m[32m78.00 B[39m
|
|
79
157
|
[32mESM[39m [1mdist/CFTTK4D6.js.map [22m[32m885.00 B[39m
|
|
158
|
+
[32mESM[39m [1mdist/strings.js.map [22m[32m71.00 B[39m
|
|
80
159
|
[32mESM[39m [1mdist/asyncify.js.map [22m[32m72.00 B[39m
|
|
81
160
|
[32mESM[39m [1mdist/branded.js.map [22m[32m71.00 B[39m
|
|
82
161
|
[32mESM[39m [1mdist/TP4DJK6G.js.map [22m[32m320.00 B[39m
|
|
162
|
+
[32mESM[39m [1mdist/B5GSIBEU.js.map [22m[32m1.40 KB[39m
|
|
83
163
|
[32mESM[39m [1mdist/6IUBP3YE.js.map [22m[32m698.00 B[39m
|
|
84
|
-
[32mESM[39m [1mdist/
|
|
164
|
+
[32mESM[39m [1mdist/deep.js.map [22m[32m68.00 B[39m
|
|
85
165
|
[32mESM[39m [1mdist/X6GYSLZB.js.map [22m[32m193.00 B[39m
|
|
166
|
+
[32mESM[39m [1mdist/constructor.js.map [22m[32m75.00 B[39m
|
|
86
167
|
[32mESM[39m [1mdist/deep.test-d.js.map [22m[32m1.45 KB[39m
|
|
87
|
-
[32mESM[39m [1mdist/deep.js.map [22m[32m68.00 B[39m
|
|
88
|
-
[32mESM[39m [1mdist/FQ2L5NQU.js.map [22m[32m759.00 B[39m
|
|
89
168
|
[32mESM[39m [1mdist/disallowedAny.js.map [22m[32m77.00 B[39m
|
|
90
|
-
[32mESM[39m [1mdist/
|
|
169
|
+
[32mESM[39m [1mdist/FQ2L5NQU.js.map [22m[32m759.00 B[39m
|
|
91
170
|
[32mESM[39m [1mdist/V353KAGF.js.map [22m[32m369.00 B[39m
|
|
92
171
|
[32mESM[39m [1mdist/identity.js.map [22m[32m72.00 B[39m
|
|
172
|
+
[32mESM[39m [1mdist/GGKJNPTT.js.map [22m[32m100.16 KB[39m
|
|
93
173
|
[32mESM[39m [1mdist/P3JODCMF.js.map [22m[32m244.00 B[39m
|
|
94
174
|
[32mESM[39m [1mdist/6AHA7PAZ.js.map [22m[32m666.00 B[39m
|
|
95
|
-
[32mESM[39m [1mdist/
|
|
175
|
+
[32mESM[39m [1mdist/TQNP6GIE.js.map [22m[32m517.00 B[39m
|
|
176
|
+
[32mESM[39m [1mdist/J7BAXUWJ.js.map [22m[32m8.24 KB[39m
|
|
96
177
|
[32mESM[39m [1mdist/CI7BVOAG.js.map [22m[32m761.96 KB[39m
|
|
97
|
-
[32mESM[39m ⚡️ Build success in
|
|
98
|
-
[32mCJS[39m [1mdist/tuples.cjs [22m[32m141.00 B[39m
|
|
99
|
-
[32mCJS[39m [1mdist/valueOf.cjs [22m[32m143.00 B[39m
|
|
100
|
-
[32mCJS[39m [1mdist/viem.cjs [22m[32m137.00 B[39m
|
|
101
|
-
[32mCJS[39m [1mdist/index.cjs [22m[32m639.00 B[39m
|
|
102
|
-
[32mCJS[39m [1mdist/EUBM3LSR.cjs [22m[32m42.53 KB[39m
|
|
103
|
-
[32mCJS[39m [1mdist/KQUDWU4T.cjs [22m[32m187.00 B[39m
|
|
104
|
-
[32mCJS[39m [1mdist/2MZ52QXI.cjs [22m[32m188.00 B[39m
|
|
105
|
-
[32mCJS[39m [1mdist/ZDGUYQPS.cjs [22m[32m185.00 B[39m
|
|
106
|
-
[32mCJS[39m [1mdist/4W25K7RR.cjs [22m[32m193.00 B[39m
|
|
107
|
-
[32mCJS[39m [1mdist/lastOf.cjs [22m[32m141.00 B[39m
|
|
108
|
-
[32mCJS[39m [1mdist/2OSBYVBM.cjs [22m[32m187.00 B[39m
|
|
109
|
-
[32mCJS[39m [1mdist/maybeUndefined.cjs [22m[32m157.00 B[39m
|
|
110
|
-
[32mCJS[39m [1mdist/7RPBI4LQ.cjs [22m[32m195.00 B[39m
|
|
111
|
-
[32mCJS[39m [1mdist/merge.cjs [22m[32m139.00 B[39m
|
|
112
|
-
[32mCJS[39m [1mdist/AKBGASRF.cjs [22m[32m186.00 B[39m
|
|
113
|
-
[32mCJS[39m [1mdist/methodOf.cjs [22m[32m145.00 B[39m
|
|
114
|
-
[32mCJS[39m [1mdist/NKWLAYNJ.cjs [22m[32m189.00 B[39m
|
|
115
|
-
[32mCJS[39m [1mdist/removeNever.cjs [22m[32m151.00 B[39m
|
|
116
|
-
[32mCJS[39m [1mdist/Q35ZNXMT.cjs [22m[32m192.00 B[39m
|
|
117
|
-
[32mCJS[39m [1mdist/strings.test-d.cjs [22m[32m904.00 B[39m
|
|
118
|
-
[32mCJS[39m [1mdist/strings.cjs [22m[32m143.00 B[39m
|
|
119
|
-
[32mCJS[39m [1mdist/K3FZ3EZT.cjs [22m[32m188.00 B[39m
|
|
120
|
-
[32mCJS[39m [1mdist/advancedRecord.cjs [22m[32m157.00 B[39m
|
|
121
|
-
[32mCJS[39m [1mdist/C7GMKBCN.cjs [22m[32m195.00 B[39m
|
|
122
|
-
[32mCJS[39m [1mdist/asyncify.cjs [22m[32m145.00 B[39m
|
|
123
|
-
[32mCJS[39m [1mdist/WPET3HPL.cjs [22m[32m189.00 B[39m
|
|
124
|
-
[32mCJS[39m [1mdist/branded.cjs [22m[32m143.00 B[39m
|
|
125
|
-
[32mCJS[39m [1mdist/2SJJDCZI.cjs [22m[32m188.00 B[39m
|
|
126
|
-
[32mCJS[39m [1mdist/constructor.cjs [22m[32m151.00 B[39m
|
|
127
|
-
[32mCJS[39m [1mdist/53OHF4EH.cjs [22m[32m192.00 B[39m
|
|
128
|
-
[32mCJS[39m [1mdist/deep.test-d.cjs [22m[32m580.00 B[39m
|
|
129
|
-
[32mCJS[39m [1mdist/deep.cjs [22m[32m137.00 B[39m
|
|
130
|
-
[32mCJS[39m [1mdist/MLSONTXK.cjs [22m[32m185.00 B[39m
|
|
131
|
-
[32mCJS[39m [1mdist/disallowedAny.cjs [22m[32m155.00 B[39m
|
|
132
|
-
[32mCJS[39m [1mdist/574X5FJM.cjs [22m[32m194.00 B[39m
|
|
133
|
-
[32mCJS[39m [1mdist/identity.cjs [22m[32m145.00 B[39m
|
|
134
|
-
[32mCJS[39m [1mdist/TVCGTTL5.cjs [22m[32m189.00 B[39m
|
|
135
|
-
[32mCJS[39m [1mdist/24WEKBY3.cjs [22m[32m2.10 KB[39m
|
|
136
|
-
[32mCJS[39m [1mdist/7BSTQVJO.cjs [22m[32m301.19 KB[39m
|
|
137
|
-
[32mCJS[39m [1mdist/withRequired.cjs [22m[32m153.00 B[39m
|
|
138
|
-
[32mCJS[39m [1mdist/tuples.cjs.map [22m[32m71.00 B[39m
|
|
139
|
-
[32mCJS[39m [1mdist/valueOf.cjs.map [22m[32m72.00 B[39m
|
|
140
|
-
[32mCJS[39m [1mdist/viem.cjs.map [22m[32m69.00 B[39m
|
|
141
|
-
[32mCJS[39m [1mdist/index.cjs.map [22m[32m665.00 B[39m
|
|
142
|
-
[32mCJS[39m [1mdist/EUBM3LSR.cjs.map [22m[32m100.19 KB[39m
|
|
143
|
-
[32mCJS[39m [1mdist/KQUDWU4T.cjs.map [22m[32m2.68 KB[39m
|
|
144
|
-
[32mCJS[39m [1mdist/2MZ52QXI.cjs.map [22m[32m538.00 B[39m
|
|
145
|
-
[32mCJS[39m [1mdist/ZDGUYQPS.cjs.map [22m[32m8.25 KB[39m
|
|
146
|
-
[32mCJS[39m [1mdist/4W25K7RR.cjs.map [22m[32m299.00 B[39m
|
|
147
|
-
[32mCJS[39m [1mdist/lastOf.cjs.map [22m[32m71.00 B[39m
|
|
148
|
-
[32mCJS[39m [1mdist/2OSBYVBM.cjs.map [22m[32m659.00 B[39m
|
|
149
|
-
[32mCJS[39m [1mdist/maybeUndefined.cjs.map [22m[32m79.00 B[39m
|
|
150
|
-
[32mCJS[39m [1mdist/7RPBI4LQ.cjs.map [22m[32m642.00 B[39m
|
|
151
|
-
[32mCJS[39m [1mdist/AKBGASRF.cjs.map [22m[32m469.00 B[39m
|
|
152
|
-
[32mCJS[39m [1mdist/merge.cjs.map [22m[32m70.00 B[39m
|
|
153
|
-
[32mCJS[39m [1mdist/methodOf.cjs.map [22m[32m73.00 B[39m
|
|
154
|
-
[32mCJS[39m [1mdist/removeNever.cjs.map [22m[32m76.00 B[39m
|
|
155
|
-
[32mCJS[39m [1mdist/Q35ZNXMT.cjs.map [22m[32m252.00 B[39m
|
|
156
|
-
[32mCJS[39m [1mdist/strings.test-d.cjs.map [22m[32m1.70 KB[39m
|
|
157
|
-
[32mCJS[39m [1mdist/strings.cjs.map [22m[32m72.00 B[39m
|
|
158
|
-
[32mCJS[39m [1mdist/NKWLAYNJ.cjs.map [22m[32m399.00 B[39m
|
|
159
|
-
[32mCJS[39m [1mdist/advancedRecord.cjs.map [22m[32m79.00 B[39m
|
|
160
|
-
[32mCJS[39m [1mdist/K3FZ3EZT.cjs.map [22m[32m1.42 KB[39m
|
|
161
|
-
[32mCJS[39m [1mdist/C7GMKBCN.cjs.map [22m[32m906.00 B[39m
|
|
162
|
-
[32mCJS[39m [1mdist/asyncify.cjs.map [22m[32m73.00 B[39m
|
|
163
|
-
[32mCJS[39m [1mdist/WPET3HPL.cjs.map [22m[32m341.00 B[39m
|
|
164
|
-
[32mCJS[39m [1mdist/branded.cjs.map [22m[32m72.00 B[39m
|
|
165
|
-
[32mCJS[39m [1mdist/2SJJDCZI.cjs.map [22m[32m719.00 B[39m
|
|
166
|
-
[32mCJS[39m [1mdist/constructor.cjs.map [22m[32m76.00 B[39m
|
|
167
|
-
[32mCJS[39m [1mdist/53OHF4EH.cjs.map [22m[32m214.00 B[39m
|
|
168
|
-
[32mCJS[39m [1mdist/deep.test-d.cjs.map [22m[32m1.47 KB[39m
|
|
169
|
-
[32mCJS[39m [1mdist/deep.cjs.map [22m[32m69.00 B[39m
|
|
170
|
-
[32mCJS[39m [1mdist/MLSONTXK.cjs.map [22m[32m780.00 B[39m
|
|
171
|
-
[32mCJS[39m [1mdist/disallowedAny.cjs.map [22m[32m78.00 B[39m
|
|
172
|
-
[32mCJS[39m [1mdist/574X5FJM.cjs.map [22m[32m390.00 B[39m
|
|
173
|
-
[32mCJS[39m [1mdist/identity.cjs.map [22m[32m73.00 B[39m
|
|
174
|
-
[32mCJS[39m [1mdist/TVCGTTL5.cjs.map [22m[32m265.00 B[39m
|
|
175
|
-
[32mCJS[39m [1mdist/24WEKBY3.cjs.map [22m[32m923.00 B[39m
|
|
176
|
-
[32mCJS[39m [1mdist/withRequired.cjs.map [22m[32m77.00 B[39m
|
|
177
|
-
[32mCJS[39m [1mdist/7BSTQVJO.cjs.map [22m[32m762.74 KB[39m
|
|
178
|
-
[32mCJS[39m ⚡️ Build success in 2358ms
|
|
178
|
+
[32mESM[39m ⚡️ Build success in 1203ms
|
package/.turbo/turbo-lint.log
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
> @layerzerolabs/typescript-utils@0.0.0 lint /home/runner/work/monorepo-internal/monorepo-internal/packages/typescript-utils
|
|
3
3
|
> eslint . --max-warnings 0 || (eslint . --fix --max-warnings 0 && false)
|
|
4
4
|
|
|
5
|
-
(node:
|
|
5
|
+
(node:43805) [MODULE_TYPELESS_PACKAGE_JSON] Warning: Module type of file:///home/runner/work/monorepo-internal/monorepo-internal/eslint.config.js?mtime=1772832456735 is not specified and it doesn't parse as CommonJS.
|
|
6
6
|
Reparsing as ES module because module syntax was detected. This incurs a performance overhead.
|
|
7
7
|
To eliminate this warning, add "type": "module" to /home/runner/work/monorepo-internal/monorepo-internal/package.json.
|
|
8
8
|
(Use `node --trace-warnings ...` to show where the warning was created)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/viem.ts"],"names":["init_cjs_shims"],"mappings":";;;;;AAAAA,4BAAA,EAAA","file":"B4TXK443.cjs","sourcesContent":["/**\n * Filters out all members of {@link T} that are not {@link P}\n *\n * @param T - Items to filter\n * @param P - Type to filter out\n * @returns Filtered items\n *\n * @example\n * type Result = Filter<['a', 'b', 'c'], 'b'>\n * // ^? type Result = ['a', 'c']\n */\nexport type Filter<\n T extends readonly unknown[],\n P,\n Acc extends readonly unknown[] = [],\n> = T extends readonly [infer F, ...infer Rest extends readonly unknown[]]\n ? [F] extends [P]\n ? Filter<Rest, P, [...Acc, F]>\n : Filter<Rest, P, Acc>\n : readonly [...Acc];\n\n/**\n * @description Checks if {@link T} can be narrowed further than {@link U}\n * @param T - Type to check\n * @param U - Type to compare against\n * @example\n * type Result = IsNarrowable<'foo', string>\n * // ^? true\n */\nexport type IsNarrowable<T, U> =\n IsNever<(T extends U ? true : false) & (U extends T ? false : true)> extends true\n ? false\n : true;\n\n/**\n * @description Checks if {@link T} is `never`\n * @param T - Type to check\n * @example\n * type Result = IsNever<never>\n * // ^? type Result = true\n */\nexport type IsNever<T> = [T] extends [never] ? true : false;\n\n/** Removes `readonly` from all properties of an object. */\nexport type Mutable<type extends object> = {\n -readonly [key in keyof type]: type[key];\n};\n\n/**\n * @description Evaluates boolean \"or\" condition for {@link T} properties.\n * @param T - Type to check\n *\n * * @example\n * type Result = Or<[false, true, false]>\n * // ^? type Result = true\n *\n * @example\n * type Result = Or<[false, false, false]>\n * // ^? type Result = false\n */\nexport type Or<T extends readonly unknown[]> = T extends readonly [infer Head, ...infer Tail]\n ? Head extends true\n ? true\n : Or<Tail>\n : false;\n\n/**\n * @description Checks if {@link T} is `undefined`\n * @param T - Type to check\n * @example\n * type Result = IsUndefined<undefined>\n * // ^? type Result = true\n */\nexport type IsUndefined<T> = [undefined] extends [T] ? true : false;\n\nexport type MaybePromise<T> = T | Promise<T>;\n\n/**\n * @description Makes attributes on the type T required if required is true.\n *\n * @example\n * MaybeRequired<{ a: string, b?: number }, true>\n * => { a: string, b: number }\n *\n * MaybeRequired<{ a: string, b?: number }, false>\n * => { a: string, b?: number }\n */\nexport type MaybeRequired<T, required extends boolean> = required extends true\n ? ExactRequired<T>\n : T;\n\n/**\n * @description Assigns the properties of U onto T.\n *\n * @example\n * Assign<{ a: string, b: number }, { a: undefined, c: boolean }>\n * => { a: undefined, b: number, c: boolean }\n */\nexport type Assign<T, U> = Assign_<T, U> & U;\ntype Assign_<T, U> = {\n [K in keyof T as K extends keyof U ? (U[K] extends void ? never : K) : K]: K extends keyof U\n ? U[K]\n : T[K];\n};\n\n// TODO: Remove when peer dep `typescript@>=4.5` (NoInfer is native)\nexport type NoInfer<type> = [type][type extends any ? 0 : never];\n\n/**\n * @description Constructs a type by excluding `undefined` from `T`.\n *\n * @example\n * NoUndefined<string | undefined>\n * => string\n *\n * @internal\n */\nexport type NoUndefined<T> = T extends undefined ? never : T;\n\n/** Strict version of built-in Omit type */\nexport type Omit<type, keys extends keyof type> = Pick<type, Exclude<keyof type, keys>>;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number }, 'a'>\n * => { a?: string, b: number }\n */\nexport type PartialBy<T, K extends keyof T> = Omit<T, K> & ExactPartial<Pick<T, K>>;\n\n/**\n * @description Combines members of an intersection into a readable type.\n *\n * @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}\n * @example\n * Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>\n * => { a: string, b: string, c: number, d: bigint }\n */\nexport type Prettify<T> = {\n [K in keyof T]: T[K];\n} & {};\n\n/** @internal */\nexport type Evaluate<type> = {\n [key in keyof type]: type[key];\n} & {};\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number }, 'a'>\n * => { a: string, b: number }\n */\nexport type RequiredBy<T, K extends keyof T> = Omit<T, K> & ExactRequired<Pick<T, K>>;\n\n/**\n * @description Returns truthy if `array` contains `value`.\n *\n * @example\n * Some<[1, 2, 3], 2>\n * => true\n */\nexport type Some<array extends readonly unknown[], value> = array extends readonly [\n value,\n ...unknown[],\n]\n ? true\n : array extends readonly [unknown, ...infer rest]\n ? Some<rest, value>\n : false;\n\nexport type UnionToTuple<\n union,\n ///\n last = LastInUnion<union>,\n> = [union] extends [never] ? [] : [...UnionToTuple<Exclude<union, last>>, last];\ntype LastInUnion<U> =\n UnionToIntersection<U extends unknown ? (x: U) => 0 : never> extends (x: infer l) => 0\n ? l\n : never;\ntype UnionToIntersection<union> = (union extends unknown ? (arg: union) => 0 : never) extends (\n arg: infer i,\n) => 0\n ? i\n : never;\n\nexport type IsUnion<\n union,\n ///\n union2 = union,\n> = union extends union2 ? ([union2] extends [union] ? false : true) : never;\n\nexport type MaybePartial<type, enabled extends boolean | undefined> = enabled extends true\n ? Prettify<ExactPartial<type>>\n : type;\n\nexport type ExactPartial<type> = {\n [key in keyof type]?: type[key] | undefined;\n};\n\nexport type ExactRequired<type> = {\n [P in keyof type]-?: Exclude<type[P], undefined>;\n};\n\nexport type OneOf<\n union extends object,\n fallback extends object | undefined = undefined,\n ///\n keys extends KeyofUnion<union> = KeyofUnion<union>,\n> = union extends infer item\n ? Prettify<\n item & {\n [key in Exclude<keys, keyof item>]?: fallback extends object\n ? key extends keyof fallback\n ? fallback[key]\n : undefined\n : undefined;\n }\n >\n : never;\ntype KeyofUnion<type> = type extends type ? keyof type : never;\n\n///////////////////////////////////////////////////////////////////////////\n// Loose types\n\n/**\n * Loose version of {@link Omit}\n * @internal\n */\nexport type LooseOmit<type, keys extends string> = Pick<type, Exclude<keyof type, keys>>;\n\n///////////////////////////////////////////////////////////////////////////\n// Union types\n\nexport type UnionEvaluate<type> = type extends object ? Prettify<type> : type;\n\nexport type UnionLooseOmit<type, keys extends string> = type extends any\n ? LooseOmit<type, keys>\n : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionOmit<type, keys extends keyof type> = type extends any ? Omit<type, keys> : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionPick<type, keys extends keyof type> = type extends any ? Pick<type, keys> : never;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { a?: string, b: number } | { a?: string, b: undefined, c: number }\n */\nexport type UnionPartialBy<T, K extends keyof T> = T extends any ? PartialBy<T, K> : never;\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number } | { a?: string, c?: number }, 'a'>\n * => { a: string, b: number } | { a: string, c?: number }\n */\nexport type UnionRequiredBy<T, K extends keyof T> = T extends any ? RequiredBy<T, K> : never;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/viem.ts"],"names":[],"mappings":";;;AAAA,cAAA,EAAA","file":"J7BAXUWJ.js","sourcesContent":["/**\n * Filters out all members of {@link T} that are not {@link P}\n *\n * @param T - Items to filter\n * @param P - Type to filter out\n * @returns Filtered items\n *\n * @example\n * type Result = Filter<['a', 'b', 'c'], 'b'>\n * // ^? type Result = ['a', 'c']\n */\nexport type Filter<\n T extends readonly unknown[],\n P,\n Acc extends readonly unknown[] = [],\n> = T extends readonly [infer F, ...infer Rest extends readonly unknown[]]\n ? [F] extends [P]\n ? Filter<Rest, P, [...Acc, F]>\n : Filter<Rest, P, Acc>\n : readonly [...Acc];\n\n/**\n * @description Checks if {@link T} can be narrowed further than {@link U}\n * @param T - Type to check\n * @param U - Type to compare against\n * @example\n * type Result = IsNarrowable<'foo', string>\n * // ^? true\n */\nexport type IsNarrowable<T, U> =\n IsNever<(T extends U ? true : false) & (U extends T ? false : true)> extends true\n ? false\n : true;\n\n/**\n * @description Checks if {@link T} is `never`\n * @param T - Type to check\n * @example\n * type Result = IsNever<never>\n * // ^? type Result = true\n */\nexport type IsNever<T> = [T] extends [never] ? true : false;\n\n/** Removes `readonly` from all properties of an object. */\nexport type Mutable<type extends object> = {\n -readonly [key in keyof type]: type[key];\n};\n\n/**\n * @description Evaluates boolean \"or\" condition for {@link T} properties.\n * @param T - Type to check\n *\n * * @example\n * type Result = Or<[false, true, false]>\n * // ^? type Result = true\n *\n * @example\n * type Result = Or<[false, false, false]>\n * // ^? type Result = false\n */\nexport type Or<T extends readonly unknown[]> = T extends readonly [infer Head, ...infer Tail]\n ? Head extends true\n ? true\n : Or<Tail>\n : false;\n\n/**\n * @description Checks if {@link T} is `undefined`\n * @param T - Type to check\n * @example\n * type Result = IsUndefined<undefined>\n * // ^? type Result = true\n */\nexport type IsUndefined<T> = [undefined] extends [T] ? true : false;\n\nexport type MaybePromise<T> = T | Promise<T>;\n\n/**\n * @description Makes attributes on the type T required if required is true.\n *\n * @example\n * MaybeRequired<{ a: string, b?: number }, true>\n * => { a: string, b: number }\n *\n * MaybeRequired<{ a: string, b?: number }, false>\n * => { a: string, b?: number }\n */\nexport type MaybeRequired<T, required extends boolean> = required extends true\n ? ExactRequired<T>\n : T;\n\n/**\n * @description Assigns the properties of U onto T.\n *\n * @example\n * Assign<{ a: string, b: number }, { a: undefined, c: boolean }>\n * => { a: undefined, b: number, c: boolean }\n */\nexport type Assign<T, U> = Assign_<T, U> & U;\ntype Assign_<T, U> = {\n [K in keyof T as K extends keyof U ? (U[K] extends void ? never : K) : K]: K extends keyof U\n ? U[K]\n : T[K];\n};\n\n// TODO: Remove when peer dep `typescript@>=4.5` (NoInfer is native)\nexport type NoInfer<type> = [type][type extends any ? 0 : never];\n\n/**\n * @description Constructs a type by excluding `undefined` from `T`.\n *\n * @example\n * NoUndefined<string | undefined>\n * => string\n *\n * @internal\n */\nexport type NoUndefined<T> = T extends undefined ? never : T;\n\n/** Strict version of built-in Omit type */\nexport type Omit<type, keys extends keyof type> = Pick<type, Exclude<keyof type, keys>>;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number }, 'a'>\n * => { a?: string, b: number }\n */\nexport type PartialBy<T, K extends keyof T> = Omit<T, K> & ExactPartial<Pick<T, K>>;\n\n/**\n * @description Combines members of an intersection into a readable type.\n *\n * @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}\n * @example\n * Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>\n * => { a: string, b: string, c: number, d: bigint }\n */\nexport type Prettify<T> = {\n [K in keyof T]: T[K];\n} & {};\n\n/** @internal */\nexport type Evaluate<type> = {\n [key in keyof type]: type[key];\n} & {};\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number }, 'a'>\n * => { a: string, b: number }\n */\nexport type RequiredBy<T, K extends keyof T> = Omit<T, K> & ExactRequired<Pick<T, K>>;\n\n/**\n * @description Returns truthy if `array` contains `value`.\n *\n * @example\n * Some<[1, 2, 3], 2>\n * => true\n */\nexport type Some<array extends readonly unknown[], value> = array extends readonly [\n value,\n ...unknown[],\n]\n ? true\n : array extends readonly [unknown, ...infer rest]\n ? Some<rest, value>\n : false;\n\nexport type UnionToTuple<\n union,\n ///\n last = LastInUnion<union>,\n> = [union] extends [never] ? [] : [...UnionToTuple<Exclude<union, last>>, last];\ntype LastInUnion<U> =\n UnionToIntersection<U extends unknown ? (x: U) => 0 : never> extends (x: infer l) => 0\n ? l\n : never;\ntype UnionToIntersection<union> = (union extends unknown ? (arg: union) => 0 : never) extends (\n arg: infer i,\n) => 0\n ? i\n : never;\n\nexport type IsUnion<\n union,\n ///\n union2 = union,\n> = union extends union2 ? ([union2] extends [union] ? false : true) : never;\n\nexport type MaybePartial<type, enabled extends boolean | undefined> = enabled extends true\n ? Prettify<ExactPartial<type>>\n : type;\n\nexport type ExactPartial<type> = {\n [key in keyof type]?: type[key] | undefined;\n};\n\nexport type ExactRequired<type> = {\n [P in keyof type]-?: Exclude<type[P], undefined>;\n};\n\nexport type OneOf<\n union extends object,\n fallback extends object | undefined = undefined,\n ///\n keys extends KeyofUnion<union> = KeyofUnion<union>,\n> = union extends infer item\n ? Prettify<\n item & {\n [key in Exclude<keys, keyof item>]?: fallback extends object\n ? key extends keyof fallback\n ? fallback[key]\n : undefined\n : undefined;\n }\n >\n : never;\ntype KeyofUnion<type> = type extends type ? keyof type : never;\n\n///////////////////////////////////////////////////////////////////////////\n// Loose types\n\n/**\n * Loose version of {@link Omit}\n * @internal\n */\nexport type LooseOmit<type, keys extends string> = Pick<type, Exclude<keyof type, keys>>;\n\n///////////////////////////////////////////////////////////////////////////\n// Union types\n\nexport type UnionEvaluate<type> = type extends object ? Prettify<type> : type;\n\nexport type UnionLooseOmit<type, keys extends string> = type extends any\n ? LooseOmit<type, keys>\n : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionOmit<type, keys extends keyof type> = type extends any ? Omit<type, keys> : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionPick<type, keys extends keyof type> = type extends any ? Pick<type, keys> : never;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { a?: string, b: number } | { a?: string, b: undefined, c: number }\n */\nexport type UnionPartialBy<T, K extends keyof T> = T extends any ? PartialBy<T, K> : never;\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number } | { a?: string, c?: number }, 'a'>\n * => { a: string, b: number } | { a: string, c?: number }\n */\nexport type UnionRequiredBy<T, K extends keyof T> = T extends any ? RequiredBy<T, K> : never;\n"]}
|
package/dist/index.cjs
CHANGED
package/dist/index.js
CHANGED
package/dist/viem.cjs
CHANGED
package/dist/viem.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ export type Filter<T extends readonly unknown[], P, Acc extends readonly unknown
|
|
|
13
13
|
/**
|
|
14
14
|
* @description Checks if {@link T} can be narrowed further than {@link U}
|
|
15
15
|
* @param T - Type to check
|
|
16
|
-
* @param U - Type to against
|
|
16
|
+
* @param U - Type to compare against
|
|
17
17
|
* @example
|
|
18
18
|
* type Result = IsNarrowable<'foo', string>
|
|
19
19
|
* // ^? true
|
package/dist/viem.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@layerzerolabs/typescript-utils",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.47",
|
|
4
4
|
"private": false,
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
"devDependencies": {
|
|
17
17
|
"tsup": "^8.4.0",
|
|
18
18
|
"vitest": "^3.2.3",
|
|
19
|
-
"@layerzerolabs/tsup-configuration": "0.2.
|
|
20
|
-
"@layerzerolabs/typescript-configuration": "0.2.
|
|
19
|
+
"@layerzerolabs/tsup-configuration": "0.2.47",
|
|
20
|
+
"@layerzerolabs/typescript-configuration": "0.2.47"
|
|
21
21
|
},
|
|
22
22
|
"publishConfig": {
|
|
23
23
|
"access": "public",
|
package/src/viem.ts
CHANGED
|
@@ -22,7 +22,7 @@ export type Filter<
|
|
|
22
22
|
/**
|
|
23
23
|
* @description Checks if {@link T} can be narrowed further than {@link U}
|
|
24
24
|
* @param T - Type to check
|
|
25
|
-
* @param U - Type to against
|
|
25
|
+
* @param U - Type to compare against
|
|
26
26
|
* @example
|
|
27
27
|
* type Result = IsNarrowable<'foo', string>
|
|
28
28
|
* // ^? true
|
package/dist/ENRZFLLD.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/viem.ts"],"names":[],"mappings":";;;AAAA,cAAA,EAAA","file":"ENRZFLLD.js","sourcesContent":["/**\n * Filters out all members of {@link T} that are not {@link P}\n *\n * @param T - Items to filter\n * @param P - Type to filter out\n * @returns Filtered items\n *\n * @example\n * type Result = Filter<['a', 'b', 'c'], 'b'>\n * // ^? type Result = ['a', 'c']\n */\nexport type Filter<\n T extends readonly unknown[],\n P,\n Acc extends readonly unknown[] = [],\n> = T extends readonly [infer F, ...infer Rest extends readonly unknown[]]\n ? [F] extends [P]\n ? Filter<Rest, P, [...Acc, F]>\n : Filter<Rest, P, Acc>\n : readonly [...Acc];\n\n/**\n * @description Checks if {@link T} can be narrowed further than {@link U}\n * @param T - Type to check\n * @param U - Type to against\n * @example\n * type Result = IsNarrowable<'foo', string>\n * // ^? true\n */\nexport type IsNarrowable<T, U> =\n IsNever<(T extends U ? true : false) & (U extends T ? false : true)> extends true\n ? false\n : true;\n\n/**\n * @description Checks if {@link T} is `never`\n * @param T - Type to check\n * @example\n * type Result = IsNever<never>\n * // ^? type Result = true\n */\nexport type IsNever<T> = [T] extends [never] ? true : false;\n\n/** Removes `readonly` from all properties of an object. */\nexport type Mutable<type extends object> = {\n -readonly [key in keyof type]: type[key];\n};\n\n/**\n * @description Evaluates boolean \"or\" condition for {@link T} properties.\n * @param T - Type to check\n *\n * * @example\n * type Result = Or<[false, true, false]>\n * // ^? type Result = true\n *\n * @example\n * type Result = Or<[false, false, false]>\n * // ^? type Result = false\n */\nexport type Or<T extends readonly unknown[]> = T extends readonly [infer Head, ...infer Tail]\n ? Head extends true\n ? true\n : Or<Tail>\n : false;\n\n/**\n * @description Checks if {@link T} is `undefined`\n * @param T - Type to check\n * @example\n * type Result = IsUndefined<undefined>\n * // ^? type Result = true\n */\nexport type IsUndefined<T> = [undefined] extends [T] ? true : false;\n\nexport type MaybePromise<T> = T | Promise<T>;\n\n/**\n * @description Makes attributes on the type T required if required is true.\n *\n * @example\n * MaybeRequired<{ a: string, b?: number }, true>\n * => { a: string, b: number }\n *\n * MaybeRequired<{ a: string, b?: number }, false>\n * => { a: string, b?: number }\n */\nexport type MaybeRequired<T, required extends boolean> = required extends true\n ? ExactRequired<T>\n : T;\n\n/**\n * @description Assigns the properties of U onto T.\n *\n * @example\n * Assign<{ a: string, b: number }, { a: undefined, c: boolean }>\n * => { a: undefined, b: number, c: boolean }\n */\nexport type Assign<T, U> = Assign_<T, U> & U;\ntype Assign_<T, U> = {\n [K in keyof T as K extends keyof U ? (U[K] extends void ? never : K) : K]: K extends keyof U\n ? U[K]\n : T[K];\n};\n\n// TODO: Remove when peer dep `typescript@>=4.5` (NoInfer is native)\nexport type NoInfer<type> = [type][type extends any ? 0 : never];\n\n/**\n * @description Constructs a type by excluding `undefined` from `T`.\n *\n * @example\n * NoUndefined<string | undefined>\n * => string\n *\n * @internal\n */\nexport type NoUndefined<T> = T extends undefined ? never : T;\n\n/** Strict version of built-in Omit type */\nexport type Omit<type, keys extends keyof type> = Pick<type, Exclude<keyof type, keys>>;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number }, 'a'>\n * => { a?: string, b: number }\n */\nexport type PartialBy<T, K extends keyof T> = Omit<T, K> & ExactPartial<Pick<T, K>>;\n\n/**\n * @description Combines members of an intersection into a readable type.\n *\n * @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}\n * @example\n * Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>\n * => { a: string, b: string, c: number, d: bigint }\n */\nexport type Prettify<T> = {\n [K in keyof T]: T[K];\n} & {};\n\n/** @internal */\nexport type Evaluate<type> = {\n [key in keyof type]: type[key];\n} & {};\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number }, 'a'>\n * => { a: string, b: number }\n */\nexport type RequiredBy<T, K extends keyof T> = Omit<T, K> & ExactRequired<Pick<T, K>>;\n\n/**\n * @description Returns truthy if `array` contains `value`.\n *\n * @example\n * Some<[1, 2, 3], 2>\n * => true\n */\nexport type Some<array extends readonly unknown[], value> = array extends readonly [\n value,\n ...unknown[],\n]\n ? true\n : array extends readonly [unknown, ...infer rest]\n ? Some<rest, value>\n : false;\n\nexport type UnionToTuple<\n union,\n ///\n last = LastInUnion<union>,\n> = [union] extends [never] ? [] : [...UnionToTuple<Exclude<union, last>>, last];\ntype LastInUnion<U> =\n UnionToIntersection<U extends unknown ? (x: U) => 0 : never> extends (x: infer l) => 0\n ? l\n : never;\ntype UnionToIntersection<union> = (union extends unknown ? (arg: union) => 0 : never) extends (\n arg: infer i,\n) => 0\n ? i\n : never;\n\nexport type IsUnion<\n union,\n ///\n union2 = union,\n> = union extends union2 ? ([union2] extends [union] ? false : true) : never;\n\nexport type MaybePartial<type, enabled extends boolean | undefined> = enabled extends true\n ? Prettify<ExactPartial<type>>\n : type;\n\nexport type ExactPartial<type> = {\n [key in keyof type]?: type[key] | undefined;\n};\n\nexport type ExactRequired<type> = {\n [P in keyof type]-?: Exclude<type[P], undefined>;\n};\n\nexport type OneOf<\n union extends object,\n fallback extends object | undefined = undefined,\n ///\n keys extends KeyofUnion<union> = KeyofUnion<union>,\n> = union extends infer item\n ? Prettify<\n item & {\n [key in Exclude<keys, keyof item>]?: fallback extends object\n ? key extends keyof fallback\n ? fallback[key]\n : undefined\n : undefined;\n }\n >\n : never;\ntype KeyofUnion<type> = type extends type ? keyof type : never;\n\n///////////////////////////////////////////////////////////////////////////\n// Loose types\n\n/**\n * Loose version of {@link Omit}\n * @internal\n */\nexport type LooseOmit<type, keys extends string> = Pick<type, Exclude<keyof type, keys>>;\n\n///////////////////////////////////////////////////////////////////////////\n// Union types\n\nexport type UnionEvaluate<type> = type extends object ? Prettify<type> : type;\n\nexport type UnionLooseOmit<type, keys extends string> = type extends any\n ? LooseOmit<type, keys>\n : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionOmit<type, keys extends keyof type> = type extends any ? Omit<type, keys> : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionPick<type, keys extends keyof type> = type extends any ? Pick<type, keys> : never;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { a?: string, b: number } | { a?: string, b: undefined, c: number }\n */\nexport type UnionPartialBy<T, K extends keyof T> = T extends any ? PartialBy<T, K> : never;\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number } | { a?: string, c?: number }, 'a'>\n * => { a: string, b: number } | { a: string, c?: number }\n */\nexport type UnionRequiredBy<T, K extends keyof T> = T extends any ? RequiredBy<T, K> : never;\n"]}
|
package/dist/ZDGUYQPS.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/viem.ts"],"names":["init_cjs_shims"],"mappings":";;;;;AAAAA,4BAAA,EAAA","file":"ZDGUYQPS.cjs","sourcesContent":["/**\n * Filters out all members of {@link T} that are not {@link P}\n *\n * @param T - Items to filter\n * @param P - Type to filter out\n * @returns Filtered items\n *\n * @example\n * type Result = Filter<['a', 'b', 'c'], 'b'>\n * // ^? type Result = ['a', 'c']\n */\nexport type Filter<\n T extends readonly unknown[],\n P,\n Acc extends readonly unknown[] = [],\n> = T extends readonly [infer F, ...infer Rest extends readonly unknown[]]\n ? [F] extends [P]\n ? Filter<Rest, P, [...Acc, F]>\n : Filter<Rest, P, Acc>\n : readonly [...Acc];\n\n/**\n * @description Checks if {@link T} can be narrowed further than {@link U}\n * @param T - Type to check\n * @param U - Type to against\n * @example\n * type Result = IsNarrowable<'foo', string>\n * // ^? true\n */\nexport type IsNarrowable<T, U> =\n IsNever<(T extends U ? true : false) & (U extends T ? false : true)> extends true\n ? false\n : true;\n\n/**\n * @description Checks if {@link T} is `never`\n * @param T - Type to check\n * @example\n * type Result = IsNever<never>\n * // ^? type Result = true\n */\nexport type IsNever<T> = [T] extends [never] ? true : false;\n\n/** Removes `readonly` from all properties of an object. */\nexport type Mutable<type extends object> = {\n -readonly [key in keyof type]: type[key];\n};\n\n/**\n * @description Evaluates boolean \"or\" condition for {@link T} properties.\n * @param T - Type to check\n *\n * * @example\n * type Result = Or<[false, true, false]>\n * // ^? type Result = true\n *\n * @example\n * type Result = Or<[false, false, false]>\n * // ^? type Result = false\n */\nexport type Or<T extends readonly unknown[]> = T extends readonly [infer Head, ...infer Tail]\n ? Head extends true\n ? true\n : Or<Tail>\n : false;\n\n/**\n * @description Checks if {@link T} is `undefined`\n * @param T - Type to check\n * @example\n * type Result = IsUndefined<undefined>\n * // ^? type Result = true\n */\nexport type IsUndefined<T> = [undefined] extends [T] ? true : false;\n\nexport type MaybePromise<T> = T | Promise<T>;\n\n/**\n * @description Makes attributes on the type T required if required is true.\n *\n * @example\n * MaybeRequired<{ a: string, b?: number }, true>\n * => { a: string, b: number }\n *\n * MaybeRequired<{ a: string, b?: number }, false>\n * => { a: string, b?: number }\n */\nexport type MaybeRequired<T, required extends boolean> = required extends true\n ? ExactRequired<T>\n : T;\n\n/**\n * @description Assigns the properties of U onto T.\n *\n * @example\n * Assign<{ a: string, b: number }, { a: undefined, c: boolean }>\n * => { a: undefined, b: number, c: boolean }\n */\nexport type Assign<T, U> = Assign_<T, U> & U;\ntype Assign_<T, U> = {\n [K in keyof T as K extends keyof U ? (U[K] extends void ? never : K) : K]: K extends keyof U\n ? U[K]\n : T[K];\n};\n\n// TODO: Remove when peer dep `typescript@>=4.5` (NoInfer is native)\nexport type NoInfer<type> = [type][type extends any ? 0 : never];\n\n/**\n * @description Constructs a type by excluding `undefined` from `T`.\n *\n * @example\n * NoUndefined<string | undefined>\n * => string\n *\n * @internal\n */\nexport type NoUndefined<T> = T extends undefined ? never : T;\n\n/** Strict version of built-in Omit type */\nexport type Omit<type, keys extends keyof type> = Pick<type, Exclude<keyof type, keys>>;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number }, 'a'>\n * => { a?: string, b: number }\n */\nexport type PartialBy<T, K extends keyof T> = Omit<T, K> & ExactPartial<Pick<T, K>>;\n\n/**\n * @description Combines members of an intersection into a readable type.\n *\n * @see {@link https://twitter.com/mattpocockuk/status/1622730173446557697?s=20&t=NdpAcmEFXY01xkqU3KO0Mg}\n * @example\n * Prettify<{ a: string } & { b: string } & { c: number, d: bigint }>\n * => { a: string, b: string, c: number, d: bigint }\n */\nexport type Prettify<T> = {\n [K in keyof T]: T[K];\n} & {};\n\n/** @internal */\nexport type Evaluate<type> = {\n [key in keyof type]: type[key];\n} & {};\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number }, 'a'>\n * => { a: string, b: number }\n */\nexport type RequiredBy<T, K extends keyof T> = Omit<T, K> & ExactRequired<Pick<T, K>>;\n\n/**\n * @description Returns truthy if `array` contains `value`.\n *\n * @example\n * Some<[1, 2, 3], 2>\n * => true\n */\nexport type Some<array extends readonly unknown[], value> = array extends readonly [\n value,\n ...unknown[],\n]\n ? true\n : array extends readonly [unknown, ...infer rest]\n ? Some<rest, value>\n : false;\n\nexport type UnionToTuple<\n union,\n ///\n last = LastInUnion<union>,\n> = [union] extends [never] ? [] : [...UnionToTuple<Exclude<union, last>>, last];\ntype LastInUnion<U> =\n UnionToIntersection<U extends unknown ? (x: U) => 0 : never> extends (x: infer l) => 0\n ? l\n : never;\ntype UnionToIntersection<union> = (union extends unknown ? (arg: union) => 0 : never) extends (\n arg: infer i,\n) => 0\n ? i\n : never;\n\nexport type IsUnion<\n union,\n ///\n union2 = union,\n> = union extends union2 ? ([union2] extends [union] ? false : true) : never;\n\nexport type MaybePartial<type, enabled extends boolean | undefined> = enabled extends true\n ? Prettify<ExactPartial<type>>\n : type;\n\nexport type ExactPartial<type> = {\n [key in keyof type]?: type[key] | undefined;\n};\n\nexport type ExactRequired<type> = {\n [P in keyof type]-?: Exclude<type[P], undefined>;\n};\n\nexport type OneOf<\n union extends object,\n fallback extends object | undefined = undefined,\n ///\n keys extends KeyofUnion<union> = KeyofUnion<union>,\n> = union extends infer item\n ? Prettify<\n item & {\n [key in Exclude<keys, keyof item>]?: fallback extends object\n ? key extends keyof fallback\n ? fallback[key]\n : undefined\n : undefined;\n }\n >\n : never;\ntype KeyofUnion<type> = type extends type ? keyof type : never;\n\n///////////////////////////////////////////////////////////////////////////\n// Loose types\n\n/**\n * Loose version of {@link Omit}\n * @internal\n */\nexport type LooseOmit<type, keys extends string> = Pick<type, Exclude<keyof type, keys>>;\n\n///////////////////////////////////////////////////////////////////////////\n// Union types\n\nexport type UnionEvaluate<type> = type extends object ? Prettify<type> : type;\n\nexport type UnionLooseOmit<type, keys extends string> = type extends any\n ? LooseOmit<type, keys>\n : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionOmit<type, keys extends keyof type> = type extends any ? Omit<type, keys> : never;\n\n/**\n * @description Construct a type with the properties of union type T except for those in type K.\n * @example\n * type Result = UnionOmit<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { b: number } | { b: undefined, c: number }\n */\nexport type UnionPick<type, keys extends keyof type> = type extends any ? Pick<type, keys> : never;\n\n/**\n * @description Creates a type that is a partial of T, but with the required keys K.\n *\n * @example\n * PartialBy<{ a: string, b: number } | { a: string, b: undefined, c: number }, 'a'>\n * => { a?: string, b: number } | { a?: string, b: undefined, c: number }\n */\nexport type UnionPartialBy<T, K extends keyof T> = T extends any ? PartialBy<T, K> : never;\n\n/**\n * @description Creates a type that is T with the required keys K.\n *\n * @example\n * RequiredBy<{ a?: string, b: number } | { a?: string, c?: number }, 'a'>\n * => { a: string, b: number } | { a: string, c?: number }\n */\nexport type UnionRequiredBy<T, K extends keyof T> = T extends any ? RequiredBy<T, K> : never;\n"]}
|