@thi.ng/csp 2.1.74 → 2.1.77
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/CHANGELOG.md +7 -1
- package/README.md +1 -1
- package/buffer.js +2 -0
- package/channel.js +17 -8
- package/mult.js +4 -2
- package/package.json +13 -14
- package/pubsub.js +4 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
|
|
3
|
-
- **Last updated**: 2023-
|
|
3
|
+
- **Last updated**: 2023-11-09T10:28:18Z
|
|
4
4
|
- **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
|
|
5
5
|
|
|
6
6
|
All notable changes to this project will be documented in this file.
|
|
@@ -9,6 +9,12 @@ See [Conventional Commits](https://conventionalcommits.org/) for commit guidelin
|
|
|
9
9
|
**Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
|
|
10
10
|
and/or version bumps of transitive dependencies.
|
|
11
11
|
|
|
12
|
+
### [2.1.76](https://github.com/thi-ng/umbrella/tree/@thi.ng/csp@2.1.76) (2023-11-09)
|
|
13
|
+
|
|
14
|
+
#### ♻️ Refactoring
|
|
15
|
+
|
|
16
|
+
- update all tests (packages A-S) ([e3085e4](https://github.com/thi-ng/umbrella/commit/e3085e4))
|
|
17
|
+
|
|
12
18
|
## [2.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/csp@2.1.0) (2021-11-17)
|
|
13
19
|
|
|
14
20
|
#### 🚀 Features
|
package/README.md
CHANGED
package/buffer.js
CHANGED
package/channel.js
CHANGED
|
@@ -213,6 +213,23 @@ export class Channel {
|
|
|
213
213
|
})();
|
|
214
214
|
return out;
|
|
215
215
|
}
|
|
216
|
+
static MAX_WRITES = 1024;
|
|
217
|
+
static NEXT_ID = 0;
|
|
218
|
+
static SCHEDULE = typeof setImmediate === "function" ? setImmediate : setTimeout;
|
|
219
|
+
static RFN = [
|
|
220
|
+
(() => null),
|
|
221
|
+
(acc) => acc,
|
|
222
|
+
(acc, x) => acc.push(x),
|
|
223
|
+
];
|
|
224
|
+
id;
|
|
225
|
+
onerror;
|
|
226
|
+
state;
|
|
227
|
+
buf;
|
|
228
|
+
tx;
|
|
229
|
+
writes;
|
|
230
|
+
reads;
|
|
231
|
+
txbuf;
|
|
232
|
+
isBusy;
|
|
216
233
|
constructor(...args) {
|
|
217
234
|
let id, buf, tx, err;
|
|
218
235
|
let [a, b] = args;
|
|
@@ -496,13 +513,5 @@ export class Channel {
|
|
|
496
513
|
this.buf.release();
|
|
497
514
|
}
|
|
498
515
|
}
|
|
499
|
-
Channel.MAX_WRITES = 1024;
|
|
500
|
-
Channel.NEXT_ID = 0;
|
|
501
|
-
Channel.SCHEDULE = typeof setImmediate === "function" ? setImmediate : setTimeout;
|
|
502
|
-
Channel.RFN = [
|
|
503
|
-
(() => null),
|
|
504
|
-
(acc) => acc,
|
|
505
|
-
(acc, x) => acc.push(x),
|
|
506
|
-
];
|
|
507
516
|
const defaultErrorHandler = (e, chan, val) => console.log(chan.id, "error occurred", e.message, val !== undefined ? val : "");
|
|
508
517
|
const maybeBuffer = (x) => x instanceof FixedBuffer || typeof x === "number";
|
package/mult.js
CHANGED
|
@@ -2,8 +2,11 @@ import { DCons } from "@thi.ng/dcons/dcons";
|
|
|
2
2
|
import { illegalArity } from "@thi.ng/errors/illegal-arity";
|
|
3
3
|
import { Channel } from "./channel.js";
|
|
4
4
|
export class Mult {
|
|
5
|
+
static nextID = 0;
|
|
6
|
+
src;
|
|
7
|
+
taps;
|
|
8
|
+
tapID = 0;
|
|
5
9
|
constructor(...args) {
|
|
6
|
-
this.tapID = 0;
|
|
7
10
|
let id, src;
|
|
8
11
|
switch (args.length) {
|
|
9
12
|
case 2:
|
|
@@ -104,4 +107,3 @@ export class Mult {
|
|
|
104
107
|
delete this.tapID;
|
|
105
108
|
}
|
|
106
109
|
}
|
|
107
|
-
Mult.nextID = 0;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/csp",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.77",
|
|
4
4
|
"description": "ES6 promise based CSP primitives & operations",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -28,29 +28,28 @@
|
|
|
28
28
|
"clean": "rimraf --glob '*.js' '*.d.ts' '*.map' doc",
|
|
29
29
|
"doc": "typedoc --excludePrivate --excludeInternal --out doc src/index.ts",
|
|
30
30
|
"doc:ae": "mkdir -p .ae/doc .ae/temp && api-extractor run --local --verbose",
|
|
31
|
-
"doc:readme": "
|
|
32
|
-
"doc:stats": "tools:module-stats",
|
|
31
|
+
"doc:readme": "bun ../../tools/src/module-stats.ts && bun ../../tools/src/readme.ts",
|
|
33
32
|
"pub": "yarn npm publish --access public",
|
|
34
|
-
"test": "
|
|
33
|
+
"test": "bun test",
|
|
35
34
|
"testasync": "tsc -p test && node build/test/async.js",
|
|
36
35
|
"testfile": "tsc -p test && node build/test/file.js",
|
|
37
36
|
"testgraph": "tsc -p test && node build/test/graph.js",
|
|
38
37
|
"testnode": "tsc -p test && node build/test/node.js"
|
|
39
38
|
},
|
|
40
39
|
"dependencies": {
|
|
41
|
-
"@thi.ng/api": "^8.9.
|
|
42
|
-
"@thi.ng/arrays": "^2.7.
|
|
43
|
-
"@thi.ng/checks": "^3.4.
|
|
44
|
-
"@thi.ng/dcons": "^3.2.
|
|
45
|
-
"@thi.ng/errors": "^2.4.
|
|
46
|
-
"@thi.ng/transducers": "^8.8.
|
|
40
|
+
"@thi.ng/api": "^8.9.8",
|
|
41
|
+
"@thi.ng/arrays": "^2.7.4",
|
|
42
|
+
"@thi.ng/checks": "^3.4.8",
|
|
43
|
+
"@thi.ng/dcons": "^3.2.72",
|
|
44
|
+
"@thi.ng/errors": "^2.4.2",
|
|
45
|
+
"@thi.ng/transducers": "^8.8.10"
|
|
47
46
|
},
|
|
48
47
|
"devDependencies": {
|
|
49
|
-
"@microsoft/api-extractor": "^7.38.
|
|
50
|
-
"@thi.ng/testament": "^0.
|
|
48
|
+
"@microsoft/api-extractor": "^7.38.2",
|
|
49
|
+
"@thi.ng/testament": "^0.4.1",
|
|
51
50
|
"rimraf": "^5.0.5",
|
|
52
51
|
"tools": "^0.0.1",
|
|
53
|
-
"typedoc": "^0.25.
|
|
52
|
+
"typedoc": "^0.25.3",
|
|
54
53
|
"typescript": "^5.2.2"
|
|
55
54
|
},
|
|
56
55
|
"keywords": [
|
|
@@ -103,5 +102,5 @@
|
|
|
103
102
|
"status": "deprecated",
|
|
104
103
|
"year": 2016
|
|
105
104
|
},
|
|
106
|
-
"gitHead": "
|
|
105
|
+
"gitHead": "669a3151e4302480244fe3e60eff5e732ea5b7a7\n"
|
|
107
106
|
}
|
package/pubsub.js
CHANGED
|
@@ -2,6 +2,10 @@ import { illegalArity } from "@thi.ng/errors/illegal-arity";
|
|
|
2
2
|
import { Channel } from "./channel.js";
|
|
3
3
|
import { Mult } from "./mult.js";
|
|
4
4
|
export class PubSub {
|
|
5
|
+
static NEXT_ID = 0;
|
|
6
|
+
src;
|
|
7
|
+
fn;
|
|
8
|
+
topics;
|
|
5
9
|
constructor(...args) {
|
|
6
10
|
switch (args.length) {
|
|
7
11
|
case 2:
|
|
@@ -86,4 +90,3 @@ export class PubSub {
|
|
|
86
90
|
delete this.fn;
|
|
87
91
|
}
|
|
88
92
|
}
|
|
89
|
-
PubSub.NEXT_ID = 0;
|