@jsonjoy.com/fs-node-builtins 4.56.1
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/LICENSE +201 -0
- package/README.md +3 -0
- package/lib/buffer.d.ts +1 -0
- package/lib/buffer.js +6 -0
- package/lib/buffer.js.map +1 -0
- package/lib/events.d.ts +1 -0
- package/lib/events.js +6 -0
- package/lib/events.js.map +1 -0
- package/lib/fs.d.ts +6 -0
- package/lib/fs.js +4 -0
- package/lib/fs.js.map +1 -0
- package/lib/internal/buffer.d.ts +9 -0
- package/lib/internal/buffer.js +13 -0
- package/lib/internal/buffer.js.map +1 -0
- package/lib/internal/errors.d.ts +31 -0
- package/lib/internal/errors.js +77 -0
- package/lib/internal/errors.js.map +1 -0
- package/lib/path.d.ts +1 -0
- package/lib/path.js +14 -0
- package/lib/path.js.map +1 -0
- package/lib/stream.d.ts +1 -0
- package/lib/stream.js +7 -0
- package/lib/stream.js.map +1 -0
- package/lib/url.d.ts +1 -0
- package/lib/url.js +6 -0
- package/lib/url.js.map +1 -0
- package/lib/util.d.ts +20 -0
- package/lib/util.js +112 -0
- package/lib/util.js.map +1 -0
- package/package.json +81 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
+
|
|
180
|
+
To apply the Apache License to your work, attach the following
|
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
+
replaced with your own identifying information. (Don't include
|
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
+
comment syntax for the file format. We also recommend that a
|
|
185
|
+
file or class name and description of purpose be included on the
|
|
186
|
+
same "printed page" as the copyright notice for easier
|
|
187
|
+
identification within third-party archives.
|
|
188
|
+
|
|
189
|
+
Copyright 2026 Vadims @streamich Daleckis <vadimsdaleckis@gmail.com>
|
|
190
|
+
|
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
+
you may not use this file except in compliance with the License.
|
|
193
|
+
You may obtain a copy of the License at
|
|
194
|
+
|
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
+
|
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
+
See the License for the specific language governing permissions and
|
|
201
|
+
limitations under the License.
|
package/README.md
ADDED
package/lib/buffer.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Buffer } from 'node:buffer';
|
package/lib/buffer.js
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Buffer = void 0;
|
|
4
|
+
var node_buffer_1 = require("node:buffer");
|
|
5
|
+
Object.defineProperty(exports, "Buffer", { enumerable: true, get: function () { return node_buffer_1.Buffer; } });
|
|
6
|
+
//# sourceMappingURL=buffer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"buffer.js","sourceRoot":"","sources":["../src/buffer.ts"],"names":[],"mappings":";;;AAAA,2CAAqC;AAA5B,qGAAA,MAAM,OAAA"}
|
package/lib/events.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { EventEmitter } from 'node:events';
|
package/lib/events.js
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.EventEmitter = void 0;
|
|
4
|
+
var node_events_1 = require("node:events");
|
|
5
|
+
Object.defineProperty(exports, "EventEmitter", { enumerable: true, get: function () { return node_events_1.EventEmitter; } });
|
|
6
|
+
//# sourceMappingURL=events.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"events.js","sourceRoot":"","sources":["../src/events.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAAlC,2GAAA,YAAY,OAAA"}
|
package/lib/fs.d.ts
ADDED
package/lib/fs.js
ADDED
package/lib/fs.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fs.js","sourceRoot":"","sources":["../src/fs.ts"],"names":[],"mappings":";AAAA,4DAA4D"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Buffer } from '../buffer';
|
|
2
|
+
declare const bufferAllocUnsafe: (size: number) => Buffer<ArrayBuffer>;
|
|
3
|
+
declare const bufferFrom: {
|
|
4
|
+
(array: import("buffer").WithImplicitCoercion<ArrayLike<number>>): Buffer<ArrayBuffer>;
|
|
5
|
+
<TArrayBuffer extends import("buffer").WithImplicitCoercion<ArrayBufferLike>>(arrayBuffer: TArrayBuffer, byteOffset?: number, length?: number): Buffer<import("buffer").ImplicitArrayBuffer<TArrayBuffer>>;
|
|
6
|
+
(string: import("buffer").WithImplicitCoercion<string>, encoding?: BufferEncoding): Buffer<ArrayBuffer>;
|
|
7
|
+
(arrayOrString: import("buffer").WithImplicitCoercion<ArrayLike<number> | string>): Buffer<ArrayBuffer>;
|
|
8
|
+
};
|
|
9
|
+
export { Buffer, bufferAllocUnsafe, bufferFrom };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.bufferFrom = exports.bufferAllocUnsafe = exports.Buffer = void 0;
|
|
4
|
+
const buffer_1 = require("../buffer");
|
|
5
|
+
Object.defineProperty(exports, "Buffer", { enumerable: true, get: function () { return buffer_1.Buffer; } });
|
|
6
|
+
function bufferV0P12Ponyfill(arg0, ...args) {
|
|
7
|
+
return new buffer_1.Buffer(arg0, ...args);
|
|
8
|
+
}
|
|
9
|
+
const bufferAllocUnsafe = buffer_1.Buffer.allocUnsafe || bufferV0P12Ponyfill;
|
|
10
|
+
exports.bufferAllocUnsafe = bufferAllocUnsafe;
|
|
11
|
+
const bufferFrom = buffer_1.Buffer.from || bufferV0P12Ponyfill;
|
|
12
|
+
exports.bufferFrom = bufferFrom;
|
|
13
|
+
//# sourceMappingURL=buffer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"buffer.js","sourceRoot":"","sources":["../../src/internal/buffer.ts"],"names":[],"mappings":";;;AAAA,sCAAmC;AAS1B,uFATA,eAAM,OASA;AAPf,SAAS,mBAAmB,CAAC,IAAS,EAAE,GAAG,IAAS;IAClD,OAAO,IAAI,eAAM,CAAC,IAAI,EAAE,GAAG,IAAI,CAAC,CAAC;AACnC,CAAC;AAED,MAAM,iBAAiB,GAAG,eAAM,CAAC,WAAW,IAAI,mBAAmB,CAAC;AAGnD,8CAAiB;AAFlC,MAAM,UAAU,GAAG,eAAM,CAAC,IAAI,IAAI,mBAAmB,CAAC;AAElB,gCAAU"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
declare const g: typeof globalThis;
|
|
2
|
+
declare class AssertionError extends g.Error {
|
|
3
|
+
generatedMessage: any;
|
|
4
|
+
name: any;
|
|
5
|
+
code: any;
|
|
6
|
+
actual: any;
|
|
7
|
+
expected: any;
|
|
8
|
+
operator: any;
|
|
9
|
+
constructor(options: any);
|
|
10
|
+
}
|
|
11
|
+
declare function message(key: any, args: any): any;
|
|
12
|
+
declare function E(sym: any, val: any): void;
|
|
13
|
+
export declare const Error: {
|
|
14
|
+
new (key: any, ...args: any[]): {
|
|
15
|
+
[x: string]: any;
|
|
16
|
+
};
|
|
17
|
+
[x: string]: any;
|
|
18
|
+
};
|
|
19
|
+
export declare const TypeError: {
|
|
20
|
+
new (key: any, ...args: any[]): {
|
|
21
|
+
[x: string]: any;
|
|
22
|
+
};
|
|
23
|
+
[x: string]: any;
|
|
24
|
+
};
|
|
25
|
+
export declare const RangeError: {
|
|
26
|
+
new (key: any, ...args: any[]): {
|
|
27
|
+
[x: string]: any;
|
|
28
|
+
};
|
|
29
|
+
[x: string]: any;
|
|
30
|
+
};
|
|
31
|
+
export { message, AssertionError, E };
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// Adapted from Node.js ../internal/errors.js, used for throwing similar errors to Node.js.
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.AssertionError = exports.RangeError = exports.TypeError = exports.Error = void 0;
|
|
5
|
+
exports.message = message;
|
|
6
|
+
exports.E = E;
|
|
7
|
+
const util_1 = require("../util");
|
|
8
|
+
const kCode = typeof Symbol === 'undefined' ? '_kCode' : Symbol('code');
|
|
9
|
+
const messages = {};
|
|
10
|
+
function makeNodeError(Base) {
|
|
11
|
+
return class NodeError extends Base {
|
|
12
|
+
constructor(key, ...args) {
|
|
13
|
+
super(message(key, args));
|
|
14
|
+
this.code = key;
|
|
15
|
+
this[kCode] = key;
|
|
16
|
+
this.name = `${super.name} [${this[kCode]}]`;
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
const g = typeof globalThis !== 'undefined' ? globalThis : global;
|
|
21
|
+
class AssertionError extends g.Error {
|
|
22
|
+
constructor(options) {
|
|
23
|
+
if (typeof options !== 'object' || options === null) {
|
|
24
|
+
throw new exports.TypeError('ERR_INVALID_ARG_TYPE', 'options', 'object');
|
|
25
|
+
}
|
|
26
|
+
if (options.message) {
|
|
27
|
+
super(options.message);
|
|
28
|
+
}
|
|
29
|
+
else {
|
|
30
|
+
super(`${(0, util_1.inspect)(options.actual).slice(0, 128)} ` + `${options.operator} ${(0, util_1.inspect)(options.expected).slice(0, 128)}`);
|
|
31
|
+
}
|
|
32
|
+
this.generatedMessage = !options.message;
|
|
33
|
+
this.name = 'AssertionError [ERR_ASSERTION]';
|
|
34
|
+
this.code = 'ERR_ASSERTION';
|
|
35
|
+
this.actual = options.actual;
|
|
36
|
+
this.expected = options.expected;
|
|
37
|
+
this.operator = options.operator;
|
|
38
|
+
exports.Error.captureStackTrace(this, options.stackStartFunction);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
exports.AssertionError = AssertionError;
|
|
42
|
+
function message(key, args) {
|
|
43
|
+
if (typeof key !== 'string')
|
|
44
|
+
throw new exports.Error('Error message key must be a string');
|
|
45
|
+
const msg = messages[key];
|
|
46
|
+
if (!msg)
|
|
47
|
+
throw new exports.Error(`An invalid error message key was used: ${key}.`);
|
|
48
|
+
let fmt;
|
|
49
|
+
if (typeof msg === 'function') {
|
|
50
|
+
fmt = msg;
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
fmt = util_1.format;
|
|
54
|
+
if (args === undefined || args.length === 0)
|
|
55
|
+
return msg;
|
|
56
|
+
args.unshift(msg);
|
|
57
|
+
}
|
|
58
|
+
return String(fmt.apply(null, args));
|
|
59
|
+
}
|
|
60
|
+
// Utility function for registering the error codes. Only used here. Exported
|
|
61
|
+
// *only* to allow for testing.
|
|
62
|
+
function E(sym, val) {
|
|
63
|
+
messages[sym] = typeof val === 'function' ? val : String(val);
|
|
64
|
+
}
|
|
65
|
+
exports.Error = makeNodeError(g.Error);
|
|
66
|
+
exports.TypeError = makeNodeError(g.TypeError);
|
|
67
|
+
exports.RangeError = makeNodeError(g.RangeError);
|
|
68
|
+
E('ERR_DIR_CLOSED', 'Directory handle was closed');
|
|
69
|
+
E('ERR_DIR_CONCURRENT_OPERATION', 'Cannot do synchronous work on directory handle with concurrent asynchronous operations');
|
|
70
|
+
E('ERR_INVALID_FILE_URL_HOST', 'File URL host must be "localhost" or empty on %s');
|
|
71
|
+
E('ERR_INVALID_FILE_URL_PATH', 'File URL path %s');
|
|
72
|
+
E('ERR_INVALID_OPT_VALUE', (name, value) => {
|
|
73
|
+
return `The value "${String(value)}" is invalid for option "${name}"`;
|
|
74
|
+
});
|
|
75
|
+
E('ERR_INVALID_OPT_VALUE_ENCODING', value => `The value "${String(value)}" is invalid for option "encoding"`);
|
|
76
|
+
E('ERR_INVALID_ARG_VALUE', 'Unable to open file as blob');
|
|
77
|
+
//# sourceMappingURL=errors.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"errors.js","sourceRoot":"","sources":["../../src/internal/errors.ts"],"names":[],"mappings":";AAAA,2FAA2F;;;AA2ElF,0BAAO;AAAkB,cAAC;AAzEnC,kCAA0C;AAE1C,MAAM,KAAK,GAAG,OAAO,MAAM,KAAK,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAE,MAAc,CAAC,MAAM,CAAC,CAAC;AACjF,MAAM,QAAQ,GAAG,EAAE,CAAC;AAEpB,SAAS,aAAa,CAAC,IAAI;IACzB,OAAO,MAAM,SAAU,SAAQ,IAAI;QACjC,YAAY,GAAG,EAAE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,CAAC,CAAC;AACvC,QAAA,UAAU,GAAG,aAAa,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC;AAItD,CAAC,CAAC,gBAAgB,EAAE,6BAA6B,CAAC,CAAC;AACnD,CAAC,CACC,8BAA8B,EAC9B,wFAAwF,CACzF,CAAC;AACF,CAAC,CAAC,2BAA2B,EAAE,kDAAkD,CAAC,CAAC;AACnF,CAAC,CAAC,2BAA2B,EAAE,kBAAkB,CAAC,CAAC;AACnD,CAAC,CAAC,uBAAuB,EAAE,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;IACzC,OAAO,cAAc,MAAM,CAAC,KAAK,CAAC,4BAA4B,IAAI,GAAG,CAAC;AACxE,CAAC,CAAC,CAAC;AACH,CAAC,CAAC,gCAAgC,EAAE,KAAK,CAAC,EAAE,CAAC,cAAc,MAAM,CAAC,KAAK,CAAC,oCAAoC,CAAC,CAAC;AAC9G,CAAC,CAAC,uBAAuB,EAAE,6BAA6B,CAAC,CAAC"}
|
package/lib/path.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { resolve, sep, posix, join, relative, dirname, normalize, isAbsolute, basename } from 'node:path';
|
package/lib/path.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.basename = exports.isAbsolute = exports.normalize = exports.dirname = exports.relative = exports.join = exports.posix = exports.sep = exports.resolve = void 0;
|
|
4
|
+
var node_path_1 = require("node:path");
|
|
5
|
+
Object.defineProperty(exports, "resolve", { enumerable: true, get: function () { return node_path_1.resolve; } });
|
|
6
|
+
Object.defineProperty(exports, "sep", { enumerable: true, get: function () { return node_path_1.sep; } });
|
|
7
|
+
Object.defineProperty(exports, "posix", { enumerable: true, get: function () { return node_path_1.posix; } });
|
|
8
|
+
Object.defineProperty(exports, "join", { enumerable: true, get: function () { return node_path_1.join; } });
|
|
9
|
+
Object.defineProperty(exports, "relative", { enumerable: true, get: function () { return node_path_1.relative; } });
|
|
10
|
+
Object.defineProperty(exports, "dirname", { enumerable: true, get: function () { return node_path_1.dirname; } });
|
|
11
|
+
Object.defineProperty(exports, "normalize", { enumerable: true, get: function () { return node_path_1.normalize; } });
|
|
12
|
+
Object.defineProperty(exports, "isAbsolute", { enumerable: true, get: function () { return node_path_1.isAbsolute; } });
|
|
13
|
+
Object.defineProperty(exports, "basename", { enumerable: true, get: function () { return node_path_1.basename; } });
|
|
14
|
+
//# sourceMappingURL=path.js.map
|
package/lib/path.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"path.js","sourceRoot":"","sources":["../src/path.ts"],"names":[],"mappings":";;;AAAA,uCAA0G;AAAjG,oGAAA,OAAO,OAAA;AAAE,gGAAA,GAAG,OAAA;AAAE,kGAAA,KAAK,OAAA;AAAE,iGAAA,IAAI,OAAA;AAAE,qGAAA,QAAQ,OAAA;AAAE,oGAAA,OAAO,OAAA;AAAE,sGAAA,SAAS,OAAA;AAAE,uGAAA,UAAU,OAAA;AAAE,qGAAA,QAAQ,OAAA"}
|
package/lib/stream.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Readable, Writable } from 'node:stream';
|
package/lib/stream.js
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Writable = exports.Readable = void 0;
|
|
4
|
+
var node_stream_1 = require("node:stream");
|
|
5
|
+
Object.defineProperty(exports, "Readable", { enumerable: true, get: function () { return node_stream_1.Readable; } });
|
|
6
|
+
Object.defineProperty(exports, "Writable", { enumerable: true, get: function () { return node_stream_1.Writable; } });
|
|
7
|
+
//# sourceMappingURL=stream.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"stream.js","sourceRoot":"","sources":["../src/stream.ts"],"names":[],"mappings":";;;AAAA,2CAAiD;AAAxC,uGAAA,QAAQ,OAAA;AAAE,uGAAA,QAAQ,OAAA"}
|
package/lib/url.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { URL } from 'node:url';
|
package/lib/url.js
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.URL = void 0;
|
|
4
|
+
var node_url_1 = require("node:url");
|
|
5
|
+
Object.defineProperty(exports, "URL", { enumerable: true, get: function () { return node_url_1.URL; } });
|
|
6
|
+
//# sourceMappingURL=url.js.map
|
package/lib/url.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"url.js","sourceRoot":"","sources":["../src/url.ts"],"names":[],"mappings":";;;AAAA,qCAA+B;AAAtB,+FAAA,GAAG,OAAA"}
|
package/lib/util.d.ts
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Minimal implementation of Node.js util.inherits function.
|
|
3
|
+
* Sets up prototype inheritance between constructor functions.
|
|
4
|
+
*/
|
|
5
|
+
export declare function inherits(ctor: any, superCtor: any): void;
|
|
6
|
+
/**
|
|
7
|
+
* Minimal implementation of Node.js util.promisify function.
|
|
8
|
+
* Converts callback-based functions to Promise-based functions.
|
|
9
|
+
*/
|
|
10
|
+
export declare function promisify(fn: Function): Function;
|
|
11
|
+
/**
|
|
12
|
+
* Minimal implementation of Node.js util.inspect function.
|
|
13
|
+
* Converts a value to a string representation for debugging.
|
|
14
|
+
*/
|
|
15
|
+
export declare function inspect(value: any): string;
|
|
16
|
+
/**
|
|
17
|
+
* Minimal implementation of Node.js util.format function.
|
|
18
|
+
* Provides printf-style string formatting with basic placeholder support.
|
|
19
|
+
*/
|
|
20
|
+
export declare function format(template: string, ...args: any[]): string;
|
package/lib/util.js
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.inherits = inherits;
|
|
4
|
+
exports.promisify = promisify;
|
|
5
|
+
exports.inspect = inspect;
|
|
6
|
+
exports.format = format;
|
|
7
|
+
/**
|
|
8
|
+
* Minimal implementation of Node.js util.inherits function.
|
|
9
|
+
* Sets up prototype inheritance between constructor functions.
|
|
10
|
+
*/
|
|
11
|
+
function inherits(ctor, superCtor) {
|
|
12
|
+
if (ctor === undefined || ctor === null) {
|
|
13
|
+
throw new TypeError('The constructor to inherit from is not defined');
|
|
14
|
+
}
|
|
15
|
+
if (superCtor === undefined || superCtor === null) {
|
|
16
|
+
throw new TypeError('The super constructor to inherit from is not defined');
|
|
17
|
+
}
|
|
18
|
+
ctor.super_ = superCtor;
|
|
19
|
+
ctor.prototype = Object.create(superCtor.prototype, {
|
|
20
|
+
constructor: {
|
|
21
|
+
value: ctor,
|
|
22
|
+
enumerable: false,
|
|
23
|
+
writable: true,
|
|
24
|
+
configurable: true,
|
|
25
|
+
},
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Minimal implementation of Node.js util.promisify function.
|
|
30
|
+
* Converts callback-based functions to Promise-based functions.
|
|
31
|
+
*/
|
|
32
|
+
function promisify(fn) {
|
|
33
|
+
if (typeof fn !== 'function') {
|
|
34
|
+
throw new TypeError('The "original" argument must be of type function');
|
|
35
|
+
}
|
|
36
|
+
return function (...args) {
|
|
37
|
+
return new Promise((resolve, reject) => {
|
|
38
|
+
fn.call(this, ...args, (err, result) => {
|
|
39
|
+
if (err) {
|
|
40
|
+
reject(err);
|
|
41
|
+
}
|
|
42
|
+
else {
|
|
43
|
+
resolve(result);
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
});
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Minimal implementation of Node.js util.inspect function.
|
|
51
|
+
* Converts a value to a string representation for debugging.
|
|
52
|
+
*/
|
|
53
|
+
function inspect(value) {
|
|
54
|
+
if (value === null)
|
|
55
|
+
return 'null';
|
|
56
|
+
if (value === undefined)
|
|
57
|
+
return 'undefined';
|
|
58
|
+
if (typeof value === 'string')
|
|
59
|
+
return `'${value}'`;
|
|
60
|
+
if (typeof value === 'number' || typeof value === 'boolean')
|
|
61
|
+
return String(value);
|
|
62
|
+
if (Array.isArray(value)) {
|
|
63
|
+
const items = value.map(item => inspect(item)).join(', ');
|
|
64
|
+
return `[ ${items} ]`;
|
|
65
|
+
}
|
|
66
|
+
if (typeof value === 'object') {
|
|
67
|
+
const entries = Object.entries(value)
|
|
68
|
+
.map(([key, val]) => `${key}: ${inspect(val)}`)
|
|
69
|
+
.join(', ');
|
|
70
|
+
return `{ ${entries} }`;
|
|
71
|
+
}
|
|
72
|
+
return String(value);
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Minimal implementation of Node.js util.format function.
|
|
76
|
+
* Provides printf-style string formatting with basic placeholder support.
|
|
77
|
+
*/
|
|
78
|
+
function format(template, ...args) {
|
|
79
|
+
if (args.length === 0)
|
|
80
|
+
return template;
|
|
81
|
+
let result = template;
|
|
82
|
+
let argIndex = 0;
|
|
83
|
+
// Replace %s (string), %d (number), %j (JSON) placeholders
|
|
84
|
+
result = result.replace(/%[sdj%]/g, match => {
|
|
85
|
+
if (argIndex >= args.length)
|
|
86
|
+
return match;
|
|
87
|
+
const arg = args[argIndex++];
|
|
88
|
+
switch (match) {
|
|
89
|
+
case '%s':
|
|
90
|
+
return String(arg);
|
|
91
|
+
case '%d':
|
|
92
|
+
return Number(arg).toString();
|
|
93
|
+
case '%j':
|
|
94
|
+
try {
|
|
95
|
+
return JSON.stringify(arg);
|
|
96
|
+
}
|
|
97
|
+
catch {
|
|
98
|
+
return '[Circular]';
|
|
99
|
+
}
|
|
100
|
+
case '%%':
|
|
101
|
+
return '%';
|
|
102
|
+
default:
|
|
103
|
+
return match;
|
|
104
|
+
}
|
|
105
|
+
});
|
|
106
|
+
// Append remaining arguments
|
|
107
|
+
while (argIndex < args.length) {
|
|
108
|
+
result += ' ' + String(args[argIndex++]);
|
|
109
|
+
}
|
|
110
|
+
return result;
|
|
111
|
+
}
|
|
112
|
+
//# sourceMappingURL=util.js.map
|
package/lib/util.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.js","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":";;AAIA,4BAgBC;AAMD,8BAgBC;AAMD,0BAgBC;AAMD,wBAmCC;AAzGD;;;GAGG;AACH,SAAgB,QAAQ,CAAC,IAAS,EAAE,SAAc;IAChD,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,IAAI,EAAE,CAAC;QACxC,MAAM,IAAI,SAAS,CAAC,gDAAgD,CAAC,CAAC;IACxE,CAAC;IACD,IAAI,SAAS,KAAK,SAAS,IAAI,SAAS,KAAK,IAAI,EAAE,CAAC;QAClD,MAAM,IAAI,SAAS,CAAC,sDAAsD,CAAC,CAAC;IAC9E,CAAC;IACD,IAAI,CAAC,MAAM,GAAG,SAAS,CAAC;IACxB,IAAI,CAAC,SAAS,GAAG,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,SAAS,EAAE;QAClD,WAAW,EAAE;YACX,KAAK,EAAE,IAAI;YACX,UAAU,EAAE,KAAK;YACjB,QAAQ,EAAE,IAAI;YACd,YAAY,EAAE,IAAI;SACnB;KACF,CAAC,CAAC;AACL,CAAC;AAED;;;GAGG;AACH,SAAgB,SAAS,CAAC,EAAY;IACpC,IAAI,OAAO,EAAE,KAAK,UAAU,EAAE,CAAC;QAC7B,MAAM,IAAI,SAAS,CAAC,kDAAkD,CAAC,CAAC;IAC1E,CAAC;IAED,OAAO,UAAU,GAAG,IAAW;QAC7B,OAAO,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE;YACrC,EAAE,CAAC,IAAI,CAAC,IAAI,EAAE,GAAG,IAAI,EAAE,CAAC,GAAQ,EAAE,MAAW,EAAE,EAAE;gBAC/C,IAA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IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,QAAQ,CAAC;IAEvC,IAAI,MAAM,GAAG,QAAQ,CAAC;IACtB,IAAI,QAAQ,GAAG,CAAC,CAAC;IAEjB,2DAA2D;IAC3D,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC,UAAU,EAAE,KAAK,CAAC,EAAE;QAC1C,IAAI,QAAQ,IAAI,IAAI,CAAC,MAAM;YAAE,OAAO,KAAK,CAAC;QAE1C,MAAM,GAAG,GAAG,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;QAC7B,QAAQ,KAAK,EAAE,CAAC;YACd,KAAK,IAAI;gBACP,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC;YACrB,KAAK,IAAI;gBACP,OAAO,MAAM,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC;YAChC,KAAK,IAAI;gBACP,IAAI,CAAC;oBACH,OAAO,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC;gBAC7B,CAAC;gBAAC,MAAM,CAAC;oBACP,OAAO,YAAY,CAAC;gBACtB,CAAC;YACH,KAAK,IAAI;gBACP,OAAO,GAAG,CAAC;YACb;gBACE,OAAO,KAAK,CAAC;QACjB,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,6BAA6B;IAC7B,OAAO,QAAQ,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC;QAC9B,MAAM,IAAI,GAAG,GAAG,MAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC;IAC3C,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@jsonjoy.com/fs-node-builtins",
|
|
3
|
+
"publishConfig": {
|
|
4
|
+
"access": "public"
|
|
5
|
+
},
|
|
6
|
+
"version": "4.56.1",
|
|
7
|
+
"description": "Node.js standard library dependencies for fs-related packages",
|
|
8
|
+
"author": {
|
|
9
|
+
"name": "streamich",
|
|
10
|
+
"url": "https://github.com/streamich"
|
|
11
|
+
},
|
|
12
|
+
"homepage": "https://github.com/streamich/memfs/tree/master/packages/fs-node-builtins",
|
|
13
|
+
"repository": "streamich/memfs",
|
|
14
|
+
"license": "Apache-2.0",
|
|
15
|
+
"funding": {
|
|
16
|
+
"type": "github",
|
|
17
|
+
"url": "https://github.com/sponsors/streamich"
|
|
18
|
+
},
|
|
19
|
+
"keywords": [
|
|
20
|
+
"node",
|
|
21
|
+
"fs",
|
|
22
|
+
"builtins",
|
|
23
|
+
"filesystem",
|
|
24
|
+
"dependencies",
|
|
25
|
+
"node builtins",
|
|
26
|
+
"node fs",
|
|
27
|
+
"node filesystem"
|
|
28
|
+
],
|
|
29
|
+
"engines": {
|
|
30
|
+
"node": ">=10.0"
|
|
31
|
+
},
|
|
32
|
+
"main": "lib/index.js",
|
|
33
|
+
"types": "lib/index.d.ts",
|
|
34
|
+
"typings": "lib/index.d.ts",
|
|
35
|
+
"files": [
|
|
36
|
+
"LICENSE",
|
|
37
|
+
"lib/"
|
|
38
|
+
],
|
|
39
|
+
"scripts": {
|
|
40
|
+
"clean": "rimraf lib typedocs coverage gh-pages yarn-error.log",
|
|
41
|
+
"build": "tsc --project tsconfig.build.json --module commonjs --target es2020 --outDir lib",
|
|
42
|
+
"jest": "node -r ts-node/register ./node_modules/.bin/jest",
|
|
43
|
+
"test": "jest --maxWorkers 7",
|
|
44
|
+
"test:ci": "yarn jest --maxWorkers 3 --no-cache",
|
|
45
|
+
"coverage": "yarn test --collectCoverage",
|
|
46
|
+
"typedoc": "typedoc",
|
|
47
|
+
"typecheck": "tsc -p ."
|
|
48
|
+
},
|
|
49
|
+
"jest": {
|
|
50
|
+
"preset": "ts-jest",
|
|
51
|
+
"testEnvironment": "node",
|
|
52
|
+
"moduleFileExtensions": [
|
|
53
|
+
"ts",
|
|
54
|
+
"js",
|
|
55
|
+
"tsx"
|
|
56
|
+
],
|
|
57
|
+
"transform": {
|
|
58
|
+
"^.+\\.tsx?$": "ts-jest"
|
|
59
|
+
},
|
|
60
|
+
"transformIgnorePatterns": [
|
|
61
|
+
".*/node_modules/.*"
|
|
62
|
+
],
|
|
63
|
+
"testRegex": ".*/(__tests__|__jest__|demo)/.*\\.(test|spec)\\.tsx?$",
|
|
64
|
+
"rootDir": ".",
|
|
65
|
+
"testPathIgnorePatterns": [
|
|
66
|
+
"node_modules"
|
|
67
|
+
]
|
|
68
|
+
},
|
|
69
|
+
"devDependencies": {
|
|
70
|
+
"@types/jest": "^29.0.0",
|
|
71
|
+
"@types/node": "^20.0.0",
|
|
72
|
+
"jest": "^29.0.0",
|
|
73
|
+
"rimraf": "^5.0.0",
|
|
74
|
+
"ts-jest": "^29.4.2",
|
|
75
|
+
"ts-node": "^10.9.2",
|
|
76
|
+
"typescript": "^5.9.2"
|
|
77
|
+
},
|
|
78
|
+
"peerDependencies": {
|
|
79
|
+
"tslib": "2"
|
|
80
|
+
}
|
|
81
|
+
}
|