@gjsify/stream 0.3.13 → 0.3.15
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/lib/esm/callable.js +2 -3
- package/lib/esm/consumers/index.js +30 -28
- package/lib/esm/index.js +1320 -1306
- package/lib/esm/promises/index.js +28 -25
- package/lib/esm/web/index.js +13 -35
- package/package.json +6 -6
- package/lib/esm/spec-internals.d.js +0 -0
|
@@ -1,30 +1,33 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { finished as finished$1, pipeline as pipeline$1 } from "../index.js";
|
|
2
|
+
|
|
3
|
+
//#region src/promises/index.ts
|
|
2
4
|
function pipeline(...streams) {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
return new Promise((resolve, reject) => {
|
|
6
|
+
pipeline$1(...streams, (err) => {
|
|
7
|
+
if (err) reject(err);
|
|
8
|
+
else resolve();
|
|
9
|
+
});
|
|
10
|
+
});
|
|
9
11
|
}
|
|
10
12
|
function finished(stream, opts) {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
13
|
+
return new Promise((resolve, reject) => {
|
|
14
|
+
if (opts && typeof opts !== "function") {
|
|
15
|
+
finished$1(stream, opts, (err) => {
|
|
16
|
+
if (err) reject(err);
|
|
17
|
+
else resolve();
|
|
18
|
+
});
|
|
19
|
+
} else {
|
|
20
|
+
finished$1(stream, (err) => {
|
|
21
|
+
if (err) reject(err);
|
|
22
|
+
else resolve();
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
});
|
|
24
26
|
}
|
|
25
|
-
var promises_default = {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
finished,
|
|
29
|
-
pipeline
|
|
27
|
+
var promises_default = {
|
|
28
|
+
pipeline,
|
|
29
|
+
finished
|
|
30
30
|
};
|
|
31
|
+
|
|
32
|
+
//#endregion
|
|
33
|
+
export { promises_default as default, finished, pipeline };
|
package/lib/esm/web/index.js
CHANGED
|
@@ -1,37 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
TransformStream,
|
|
5
|
-
ByteLengthQueuingStrategy,
|
|
6
|
-
CountQueuingStrategy,
|
|
7
|
-
TextEncoderStream,
|
|
8
|
-
TextDecoderStream
|
|
9
|
-
} from "@gjsify/web-streams";
|
|
10
|
-
import {
|
|
11
|
-
ReadableStream as ReadableStream2,
|
|
12
|
-
WritableStream as WritableStream2,
|
|
13
|
-
TransformStream as TransformStream2,
|
|
14
|
-
ByteLengthQueuingStrategy as ByteLengthQueuingStrategy2,
|
|
15
|
-
CountQueuingStrategy as CountQueuingStrategy2,
|
|
16
|
-
TextEncoderStream as TextEncoderStream2,
|
|
17
|
-
TextDecoderStream as TextDecoderStream2
|
|
18
|
-
} from "@gjsify/web-streams";
|
|
1
|
+
import { ByteLengthQueuingStrategy, ByteLengthQueuingStrategy as ByteLengthQueuingStrategy$1, CountQueuingStrategy, CountQueuingStrategy as CountQueuingStrategy$1, ReadableStream, ReadableStream as ReadableStream$1, TextDecoderStream, TextDecoderStream as TextDecoderStream$1, TextEncoderStream, TextEncoderStream as TextEncoderStream$1, TransformStream, TransformStream as TransformStream$1, WritableStream, WritableStream as WritableStream$1 } from "@gjsify/web-streams";
|
|
2
|
+
|
|
3
|
+
//#region src/web/index.ts
|
|
19
4
|
var web_default = {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
};
|
|
28
|
-
export {
|
|
29
|
-
ByteLengthQueuingStrategy,
|
|
30
|
-
CountQueuingStrategy,
|
|
31
|
-
ReadableStream,
|
|
32
|
-
TextDecoderStream,
|
|
33
|
-
TextEncoderStream,
|
|
34
|
-
TransformStream,
|
|
35
|
-
WritableStream,
|
|
36
|
-
web_default as default
|
|
5
|
+
ReadableStream: ReadableStream$1,
|
|
6
|
+
WritableStream: WritableStream$1,
|
|
7
|
+
TransformStream: TransformStream$1,
|
|
8
|
+
ByteLengthQueuingStrategy: ByteLengthQueuingStrategy$1,
|
|
9
|
+
CountQueuingStrategy: CountQueuingStrategy$1,
|
|
10
|
+
TextEncoderStream: TextEncoderStream$1,
|
|
11
|
+
TextDecoderStream: TextDecoderStream$1
|
|
37
12
|
};
|
|
13
|
+
|
|
14
|
+
//#endregion
|
|
15
|
+
export { ByteLengthQueuingStrategy, CountQueuingStrategy, ReadableStream, TextDecoderStream, TextEncoderStream, TransformStream, WritableStream, web_default as default };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gjsify/stream",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.15",
|
|
4
4
|
"description": "Node.js stream module for Gjs",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "lib/esm/index.js",
|
|
@@ -43,14 +43,14 @@
|
|
|
43
43
|
"stream"
|
|
44
44
|
],
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"@gjsify/cli": "^0.3.
|
|
47
|
-
"@gjsify/unit": "^0.3.
|
|
46
|
+
"@gjsify/cli": "^0.3.15",
|
|
47
|
+
"@gjsify/unit": "^0.3.15",
|
|
48
48
|
"@types/node": "^25.6.0",
|
|
49
49
|
"typescript": "^6.0.3"
|
|
50
50
|
},
|
|
51
51
|
"dependencies": {
|
|
52
|
-
"@gjsify/events": "^0.3.
|
|
53
|
-
"@gjsify/utils": "^0.3.
|
|
54
|
-
"@gjsify/web-streams": "^0.3.
|
|
52
|
+
"@gjsify/events": "^0.3.15",
|
|
53
|
+
"@gjsify/utils": "^0.3.15",
|
|
54
|
+
"@gjsify/web-streams": "^0.3.15"
|
|
55
55
|
}
|
|
56
56
|
}
|
|
File without changes
|