@btc-vision/transaction 1.7.24 → 1.7.26

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.
@@ -1,410 +0,0 @@
1
- import { a as ue } from "./bip39.js";
2
- function A(e) {
3
- return e instanceof Uint8Array || ArrayBuffer.isView(e) && e.constructor.name === "Uint8Array";
4
- }
5
- function H(e) {
6
- if (!A(e))
7
- throw new Error("Uint8Array expected");
8
- }
9
- function K(e, r) {
10
- return Array.isArray(r) ? r.length === 0 ? !0 : e ? r.every((n) => typeof n == "string") : r.every((n) => Number.isSafeInteger(n)) : !1;
11
- }
12
- function D(e) {
13
- if (typeof e != "function")
14
- throw new Error("function expected");
15
- return !0;
16
- }
17
- function b(e, r) {
18
- if (typeof r != "string")
19
- throw new Error(`${e}: string expected`);
20
- return !0;
21
- }
22
- function m(e) {
23
- if (!Number.isSafeInteger(e))
24
- throw new Error(`invalid integer: ${e}`);
25
- }
26
- function k(e) {
27
- if (!Array.isArray(e))
28
- throw new Error("array expected");
29
- }
30
- function R(e, r) {
31
- if (!K(!0, r))
32
- throw new Error(`${e}: array of strings expected`);
33
- }
34
- function M(e, r) {
35
- if (!K(!1, r))
36
- throw new Error(`${e}: array of numbers expected`);
37
- }
38
- // @__NO_SIDE_EFFECTS__
39
- function f(...e) {
40
- const r = (o) => o, n = (o, s) => (i) => o(s(i)), c = e.map((o) => o.encode).reduceRight(n, r), t = e.map((o) => o.decode).reduce(n, r);
41
- return { encode: c, decode: t };
42
- }
43
- // @__NO_SIDE_EFFECTS__
44
- function u(e) {
45
- const r = typeof e == "string" ? e.split("") : e, n = r.length;
46
- R("alphabet", r);
47
- const c = new Map(r.map((t, o) => [t, o]));
48
- return {
49
- encode: (t) => (k(t), t.map((o) => {
50
- if (!Number.isSafeInteger(o) || o < 0 || o >= n)
51
- throw new Error(`alphabet.encode: digit index outside alphabet "${o}". Allowed: ${e}`);
52
- return r[o];
53
- })),
54
- decode: (t) => (k(t), t.map((o) => {
55
- b("alphabet.decode", o);
56
- const s = c.get(o);
57
- if (s === void 0)
58
- throw new Error(`Unknown letter: "${o}". Allowed: ${e}`);
59
- return s;
60
- }))
61
- };
62
- }
63
- // @__NO_SIDE_EFFECTS__
64
- function l(e = "") {
65
- return b("join", e), {
66
- encode: (r) => (R("join.decode", r), r.join(e)),
67
- decode: (r) => (b("join.decode", r), r.split(e))
68
- };
69
- }
70
- // @__NO_SIDE_EFFECTS__
71
- function T(e, r = "=") {
72
- return m(e), b("padding", r), {
73
- encode(n) {
74
- for (R("padding.encode", n); n.length * e % 8; )
75
- n.push(r);
76
- return n;
77
- },
78
- decode(n) {
79
- R("padding.decode", n);
80
- let c = n.length;
81
- if (c * e % 8)
82
- throw new Error("padding: invalid, string should have whole number of bytes");
83
- for (; c > 0 && n[c - 1] === r; c--)
84
- if ((c - 1) * e % 8 === 0)
85
- throw new Error("padding: invalid, string has too much padding");
86
- return n.slice(0, c);
87
- }
88
- };
89
- }
90
- // @__NO_SIDE_EFFECTS__
91
- function V(e) {
92
- return D(e), { encode: (r) => r, decode: (r) => e(r) };
93
- }
94
- function O(e, r, n) {
95
- if (r < 2)
96
- throw new Error(`convertRadix: invalid from=${r}, base cannot be less than 2`);
97
- if (n < 2)
98
- throw new Error(`convertRadix: invalid to=${n}, base cannot be less than 2`);
99
- if (k(e), !e.length)
100
- return [];
101
- let c = 0;
102
- const t = [], o = Array.from(e, (i) => {
103
- if (m(i), i < 0 || i >= r)
104
- throw new Error(`invalid integer: ${i}`);
105
- return i;
106
- }), s = o.length;
107
- for (; ; ) {
108
- let i = 0, g = !0;
109
- for (let p = c; p < s; p++) {
110
- const x = o[p], d = r * i, a = d + x;
111
- if (!Number.isSafeInteger(a) || d / r !== i || a - x !== d)
112
- throw new Error("convertRadix: carry overflow");
113
- const y = a / n;
114
- i = a % n;
115
- const h = Math.floor(y);
116
- if (o[p] = h, !Number.isSafeInteger(h) || h * n + i !== a)
117
- throw new Error("convertRadix: carry overflow");
118
- if (g)
119
- h ? g = !1 : c = p;
120
- else continue;
121
- }
122
- if (t.push(i), g)
123
- break;
124
- }
125
- for (let i = 0; i < e.length - 1 && e[i] === 0; i++)
126
- t.push(0);
127
- return t.reverse();
128
- }
129
- const J = (e, r) => r === 0 ? e : J(r, e % r), S = /* @__NO_SIDE_EFFECTS__ */ (e, r) => e + (r - J(e, r)), C = /* @__PURE__ */ (() => {
130
- let e = [];
131
- for (let r = 0; r < 40; r++)
132
- e.push(2 ** r);
133
- return e;
134
- })();
135
- function N(e, r, n, c) {
136
- if (k(e), r <= 0 || r > 32)
137
- throw new Error(`convertRadix2: wrong from=${r}`);
138
- if (n <= 0 || n > 32)
139
- throw new Error(`convertRadix2: wrong to=${n}`);
140
- if (/* @__PURE__ */ S(r, n) > 32)
141
- throw new Error(`convertRadix2: carry overflow from=${r} to=${n} carryBits=${/* @__PURE__ */ S(r, n)}`);
142
- let t = 0, o = 0;
143
- const s = C[r], i = C[n] - 1, g = [];
144
- for (const p of e) {
145
- if (m(p), p >= s)
146
- throw new Error(`convertRadix2: invalid data word=${p} from=${r}`);
147
- if (t = t << r | p, o + r > 32)
148
- throw new Error(`convertRadix2: carry overflow pos=${o} from=${r}`);
149
- for (o += r; o >= n; o -= n)
150
- g.push((t >> o - n & i) >>> 0);
151
- const x = C[o];
152
- if (x === void 0)
153
- throw new Error("invalid carry");
154
- t &= x - 1;
155
- }
156
- if (t = t << n - o & i, !c && o >= r)
157
- throw new Error("Excess padding");
158
- if (!c && t > 0)
159
- throw new Error(`Non-zero padding: ${t}`);
160
- return c && o > 0 && g.push(t >>> 0), g;
161
- }
162
- // @__NO_SIDE_EFFECTS__
163
- function Q(e) {
164
- m(e);
165
- const r = 2 ** 8;
166
- return {
167
- encode: (n) => {
168
- if (!A(n))
169
- throw new Error("radix.encode input should be Uint8Array");
170
- return O(Array.from(n), r, e);
171
- },
172
- decode: (n) => (M("radix.decode", n), Uint8Array.from(O(n, e, r)))
173
- };
174
- }
175
- // @__NO_SIDE_EFFECTS__
176
- function w(e, r = !1) {
177
- if (m(e), e <= 0 || e > 32)
178
- throw new Error("radix2: bits should be in (0..32]");
179
- if (/* @__PURE__ */ S(8, e) > 32 || /* @__PURE__ */ S(e, 8) > 32)
180
- throw new Error("radix2: carry overflow");
181
- return {
182
- encode: (n) => {
183
- if (!A(n))
184
- throw new Error("radix2.encode input should be Uint8Array");
185
- return N(Array.from(n), 8, e, !r);
186
- },
187
- decode: (n) => (M("radix2.decode", n), Uint8Array.from(N(n, e, 8, r)))
188
- };
189
- }
190
- function F(e) {
191
- return D(e), function(...r) {
192
- try {
193
- return e.apply(null, r);
194
- } catch {
195
- }
196
- };
197
- }
198
- function Z(e, r) {
199
- return m(e), D(r), {
200
- encode(n) {
201
- if (!A(n))
202
- throw new Error("checksum.encode: input should be Uint8Array");
203
- const c = r(n).slice(0, e), t = new Uint8Array(n.length + e);
204
- return t.set(n), t.set(c, n.length), t;
205
- },
206
- decode(n) {
207
- if (!A(n))
208
- throw new Error("checksum.decode: input should be Uint8Array");
209
- const c = n.slice(0, -e), t = n.slice(-e), o = r(c).slice(0, e);
210
- for (let s = 0; s < e; s++)
211
- if (o[s] !== t[s])
212
- throw new Error("Invalid checksum");
213
- return c;
214
- }
215
- };
216
- }
217
- const le = {
218
- alphabet: u,
219
- chain: f,
220
- checksum: Z,
221
- convertRadix: O,
222
- convertRadix2: N,
223
- radix: Q,
224
- radix2: w,
225
- join: l,
226
- padding: T
227
- }, X = /* @__PURE__ */ f(/* @__PURE__ */ w(4), /* @__PURE__ */ u("0123456789ABCDEF"), /* @__PURE__ */ l("")), Y = /* @__PURE__ */ f(/* @__PURE__ */ w(5), /* @__PURE__ */ u("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"), /* @__PURE__ */ T(5), /* @__PURE__ */ l("")), he = /* @__PURE__ */ f(/* @__PURE__ */ w(5), /* @__PURE__ */ u("ABCDEFGHIJKLMNOPQRSTUVWXYZ234567"), /* @__PURE__ */ l("")), we = /* @__PURE__ */ f(/* @__PURE__ */ w(5), /* @__PURE__ */ u("0123456789ABCDEFGHIJKLMNOPQRSTUV"), /* @__PURE__ */ T(5), /* @__PURE__ */ l("")), pe = /* @__PURE__ */ f(/* @__PURE__ */ w(5), /* @__PURE__ */ u("0123456789ABCDEFGHIJKLMNOPQRSTUV"), /* @__PURE__ */ l("")), ye = /* @__PURE__ */ f(/* @__PURE__ */ w(5), /* @__PURE__ */ u("0123456789ABCDEFGHJKMNPQRSTVWXYZ"), /* @__PURE__ */ l(""), /* @__PURE__ */ V((e) => e.toUpperCase().replace(/O/g, "0").replace(/[IL]/g, "1"))), q = typeof Uint8Array.from([]).toBase64 == "function" && typeof Uint8Array.fromBase64 == "function", ee = (e, r) => {
228
- b("base64", e);
229
- const n = r ? /^[A-Za-z0-9=_-]+$/ : /^[A-Za-z0-9=+/]+$/, c = r ? "base64url" : "base64";
230
- if (e.length > 0 && !n.test(e))
231
- throw new Error("invalid base64");
232
- return Uint8Array.fromBase64(e, { alphabet: c, lastChunkHandling: "strict" });
233
- }, re = q ? {
234
- encode(e) {
235
- return H(e), e.toBase64();
236
- },
237
- decode(e) {
238
- return ee(e, !1);
239
- }
240
- } : /* @__PURE__ */ f(/* @__PURE__ */ w(6), /* @__PURE__ */ u("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"), /* @__PURE__ */ T(6), /* @__PURE__ */ l("")), ge = /* @__PURE__ */ f(/* @__PURE__ */ w(6), /* @__PURE__ */ u("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"), /* @__PURE__ */ l("")), ne = q ? {
241
- encode(e) {
242
- return H(e), e.toBase64({ alphabet: "base64url" });
243
- },
244
- decode(e) {
245
- return ee(e, !0);
246
- }
247
- } : /* @__PURE__ */ f(/* @__PURE__ */ w(6), /* @__PURE__ */ u("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"), /* @__PURE__ */ T(6), /* @__PURE__ */ l("")), be = /* @__PURE__ */ f(/* @__PURE__ */ w(6), /* @__PURE__ */ u("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"), /* @__PURE__ */ l("")), P = /* @__NO_SIDE_EFFECTS__ */ (e) => /* @__PURE__ */ f(/* @__PURE__ */ Q(58), /* @__PURE__ */ u(e), /* @__PURE__ */ l("")), U = /* @__PURE__ */ P("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"), xe = /* @__PURE__ */ P("123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"), Ee = /* @__PURE__ */ P("rpshnaf39wBUDNEGHJKLM4PQRST7VWXYZ2bcdeCg65jkm8oFqi1tuvAxyz"), G = [0, 2, 3, 5, 6, 7, 9, 10, 11], oe = {
248
- encode(e) {
249
- let r = "";
250
- for (let n = 0; n < e.length; n += 8) {
251
- const c = e.subarray(n, n + 8);
252
- r += U.encode(c).padStart(G[c.length], "1");
253
- }
254
- return r;
255
- },
256
- decode(e) {
257
- let r = [];
258
- for (let n = 0; n < e.length; n += 11) {
259
- const c = e.slice(n, n + 11), t = G.indexOf(c.length), o = U.decode(c);
260
- for (let s = 0; s < o.length - t; s++)
261
- if (o[s] !== 0)
262
- throw new Error("base58xmr: wrong padding");
263
- r = r.concat(Array.from(o.slice(o.length - t)));
264
- }
265
- return Uint8Array.from(r);
266
- }
267
- }, te = (e) => /* @__PURE__ */ f(Z(4, (r) => e(e(r))), U), Ae = te, I = /* @__PURE__ */ f(/* @__PURE__ */ u("qpzry9x8gf2tvdw0s3jn54khce6mua7l"), /* @__PURE__ */ l("")), _ = [996825010, 642813549, 513874426, 1027748829, 705979059];
268
- function B(e) {
269
- const r = e >> 25;
270
- let n = (e & 33554431) << 5;
271
- for (let c = 0; c < _.length; c++)
272
- (r >> c & 1) === 1 && (n ^= _[c]);
273
- return n;
274
- }
275
- function z(e, r, n = 1) {
276
- const c = e.length;
277
- let t = 1;
278
- for (let o = 0; o < c; o++) {
279
- const s = e.charCodeAt(o);
280
- if (s < 33 || s > 126)
281
- throw new Error(`Invalid prefix (${e})`);
282
- t = B(t) ^ s >> 5;
283
- }
284
- t = B(t);
285
- for (let o = 0; o < c; o++)
286
- t = B(t) ^ e.charCodeAt(o) & 31;
287
- for (let o of r)
288
- t = B(t) ^ o;
289
- for (let o = 0; o < 6; o++)
290
- t = B(t);
291
- return t ^= n, I.encode(N([t % C[30]], 30, 5, !1));
292
- }
293
- // @__NO_SIDE_EFFECTS__
294
- function ce(e) {
295
- const r = e === "bech32" ? 1 : 734539939, n = /* @__PURE__ */ w(5), c = n.decode, t = n.encode, o = F(c);
296
- function s(d, a, y = 90) {
297
- b("bech32.encode prefix", d), A(a) && (a = Array.from(a)), M("bech32.encode", a);
298
- const h = d.length;
299
- if (h === 0)
300
- throw new TypeError(`Invalid prefix length ${h}`);
301
- const E = h + 7 + a.length;
302
- if (y !== !1 && E > y)
303
- throw new TypeError(`Length ${E} exceeds limit ${y}`);
304
- const v = d.toLowerCase(), $ = z(v, a, r);
305
- return `${v}1${I.encode(a)}${$}`;
306
- }
307
- function i(d, a = 90) {
308
- b("bech32.decode input", d);
309
- const y = d.length;
310
- if (y < 8 || a !== !1 && y > a)
311
- throw new TypeError(`invalid string length: ${y} (${d}). Expected (8..${a})`);
312
- const h = d.toLowerCase();
313
- if (d !== h && d !== d.toUpperCase())
314
- throw new Error("String must be lowercase or uppercase");
315
- const E = h.lastIndexOf("1");
316
- if (E === 0 || E === -1)
317
- throw new Error('Letter "1" must be present between prefix and data only');
318
- const v = h.slice(0, E), $ = h.slice(E + 1);
319
- if ($.length < 6)
320
- throw new Error("Data must be at least 6 characters long");
321
- const j = I.decode($).slice(0, -6), W = z(v, j, r);
322
- if (!$.endsWith(W))
323
- throw new Error(`Invalid checksum in ${d}: expected "${W}"`);
324
- return { prefix: v, words: j };
325
- }
326
- const g = F(i);
327
- function p(d) {
328
- const { prefix: a, words: y } = i(d, !1);
329
- return { prefix: a, words: y, bytes: c(y) };
330
- }
331
- function x(d, a) {
332
- return s(d, t(a));
333
- }
334
- return {
335
- encode: s,
336
- decode: i,
337
- encodeFromBytes: x,
338
- decodeToBytes: p,
339
- decodeUnsafe: g,
340
- fromWords: c,
341
- fromWordsUnsafe: o,
342
- toWords: t
343
- };
344
- }
345
- const me = /* @__PURE__ */ ce("bech32"), ve = /* @__PURE__ */ ce("bech32m"), se = {
346
- encode: (e) => new TextDecoder().decode(e),
347
- decode: (e) => new TextEncoder().encode(e)
348
- }, $e = typeof Uint8Array.from([]).toHex == "function" && typeof Uint8Array.fromHex == "function", Be = {
349
- encode(e) {
350
- return H(e), e.toHex();
351
- },
352
- decode(e) {
353
- return b("hex", e), Uint8Array.fromHex(e);
354
- }
355
- }, ie = $e ? Be : /* @__PURE__ */ f(/* @__PURE__ */ w(4), /* @__PURE__ */ u("0123456789abcdef"), /* @__PURE__ */ l(""), /* @__PURE__ */ V((e) => {
356
- if (typeof e != "string" || e.length % 2 !== 0)
357
- throw new TypeError(`hex.decode: expected string, got ${typeof e} with length ${e.length}`);
358
- return e.toLowerCase();
359
- })), L = {
360
- utf8: se,
361
- hex: ie,
362
- base16: X,
363
- base32: Y,
364
- base64: re,
365
- base64url: ne,
366
- base58: U,
367
- base58xmr: oe
368
- }, ae = "Invalid encoding type. Available types: utf8, hex, base16, base32, base64, base64url, base58, base58xmr", de = (e, r) => {
369
- if (typeof e != "string" || !L.hasOwnProperty(e))
370
- throw new TypeError(ae);
371
- if (!A(r))
372
- throw new TypeError("bytesToString() expects Uint8Array");
373
- return L[e].encode(r);
374
- }, Ue = de, fe = (e, r) => {
375
- if (!L.hasOwnProperty(e))
376
- throw new TypeError(ae);
377
- if (typeof r != "string")
378
- throw new TypeError("stringToBytes() expects string");
379
- return L[e].decode(r);
380
- }, Te = fe, Ce = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
381
- __proto__: null,
382
- base16: X,
383
- base32: Y,
384
- base32crockford: ye,
385
- base32hex: we,
386
- base32hexnopad: pe,
387
- base32nopad: he,
388
- base58: U,
389
- base58check: Ae,
390
- base58flickr: xe,
391
- base58xmr: oe,
392
- base58xrp: Ee,
393
- base64: re,
394
- base64nopad: ge,
395
- base64url: ne,
396
- base64urlnopad: be,
397
- bech32: me,
398
- bech32m: ve,
399
- bytes: Te,
400
- bytesToString: de,
401
- createBase58check: te,
402
- hex: ie,
403
- str: Ue,
404
- stringToBytes: fe,
405
- utf8: se,
406
- utils: le
407
- }, Symbol.toStringTag, { value: "Module" })), Re = /* @__PURE__ */ ue(Ce);
408
- export {
409
- Re as r
410
- };
@@ -1,11 +0,0 @@
1
- export function createHash(algo: any): import("@noble/hashes/utils").Hash<import("@noble/hashes/utils").Hash<any>> | undefined;
2
- export function createHmac(_algo: any, key: any): import("@noble/hashes/hmac").HMAC<any>;
3
- export function pbkdf2Sync(password: any, salt: any, iterations: any, keylen: any, _algo: any): Uint8Array<ArrayBufferLike>;
4
- export function randomBytes(length: any): Uint8Array<any>;
5
- declare namespace _default {
6
- export { createHash };
7
- export { createHmac };
8
- export { pbkdf2Sync };
9
- export { randomBytes };
10
- }
11
- export default _default;
@@ -1,56 +0,0 @@
1
- import { hmac } from '@noble/hashes/hmac';
2
- import { pbkdf2 } from '@noble/hashes/pbkdf2';
3
- import { sha256 } from '@noble/hashes/sha256';
4
- import { sha512 } from '@noble/hashes/sha512';
5
- import assert from 'assert';
6
- function assertArgument(check, message, name, value) {
7
- assert(check, message, 'INVALID_ARGUMENT', { argument: name, value: value });
8
- }
9
- function getGlobal() {
10
- if (typeof self !== 'undefined') {
11
- return self;
12
- }
13
- if (typeof window !== 'undefined') {
14
- return window;
15
- }
16
- if (typeof global !== 'undefined') {
17
- return global;
18
- }
19
- throw new Error('unable to locate global object');
20
- }
21
- const anyGlobal = getGlobal();
22
- const crypto = anyGlobal.crypto || anyGlobal.msCrypto;
23
- export function createHash(algo) {
24
- switch (algo) {
25
- case 'sha256':
26
- return sha256.create();
27
- case 'sha512':
28
- return sha512.create();
29
- }
30
- assertArgument(false, 'invalid hashing algorithm name', 'algorithm', algo);
31
- }
32
- export function createHmac(_algo, key) {
33
- const algo = { sha256, sha512 }[_algo];
34
- assertArgument(algo != null, 'invalid hmac algorithm', 'algorithm', _algo);
35
- return hmac.create(algo, key);
36
- }
37
- export function pbkdf2Sync(password, salt, iterations, keylen, _algo) {
38
- const algo = { sha256, sha512 }[_algo];
39
- assertArgument(algo != null, 'invalid pbkdf2 algorithm', 'algorithm', _algo);
40
- return pbkdf2(algo, password, salt, { c: iterations, dkLen: keylen });
41
- }
42
- export function randomBytes(length) {
43
- assert(crypto != null, 'platform does not support secure random numbers', 'UNSUPPORTED_OPERATION', {
44
- operation: 'randomBytes',
45
- });
46
- assertArgument(Number.isInteger(length) && length > 0 && length <= 1024, 'invalid length', 'length', length);
47
- const result = new Uint8Array(length);
48
- crypto.getRandomValues(result);
49
- return result;
50
- }
51
- export default {
52
- createHash,
53
- createHmac,
54
- pbkdf2Sync,
55
- randomBytes,
56
- };
package/gulpfile.js DELETED
@@ -1,42 +0,0 @@
1
- import gulpESLintNew from 'gulp-eslint-new';
2
- import gulp from 'gulp';
3
- import gulpcache from 'gulp-cached';
4
-
5
- import gulpClean from 'gulp-clean';
6
- import logger from 'gulp-logger-new';
7
- import ts from 'gulp-typescript';
8
-
9
- process.on('uncaughtException', function (err) {
10
- console.log('Caught exception: ', err);
11
- });
12
-
13
- const tsProject = ts.createProject('tsconfig.json');
14
-
15
- function buildESM() {
16
- return gulp
17
- .src(['src/**/*.ts', 'src/**/*.js', '!test/**/*'])
18
- .pipe(gulpcache('ts-esm'))
19
- .pipe(
20
- logger({
21
- before: 'Starting...',
22
- after: 'Project compiled!',
23
- extname: '.js',
24
- showChange: true,
25
- }),
26
- )
27
- .pipe(gulpESLintNew())
28
- .pipe(gulpESLintNew.format())
29
- .pipe(tsProject())
30
- .pipe(gulp.dest('build'));
31
- }
32
-
33
- export async function clean() {
34
- return gulp.src('./build/src', { read: false }).pipe(gulpClean());
35
- }
36
-
37
- export const build = buildESM;
38
- export default build;
39
-
40
- export function watch() {
41
- gulp.watch(['src/**/*.ts', 'src/**/*.js'], gulp.series(buildESM));
42
- }