@thi.ng/fibers 0.3.1 → 0.3.3
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 +1 -1
- package/README.md +1 -0
- package/fiber.js +2 -1
- package/package.json +13 -13
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -401,6 +401,7 @@ A selection:
|
|
|
401
401
|
|:----------------------------------------------------------------------------------------------------------------------|:------------------------------------------------------------------|:-----------------------------------------------------|:----------------------------------------------------------------------------------|
|
|
402
402
|
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/ascii-raymarch.jpg" width="240"/> | ASCII art raymarching with thi.ng/shader-ast & thi.ng/text-canvas | [Demo](https://demo.thi.ng/umbrella/ascii-raymarch/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/ascii-raymarch) |
|
|
403
403
|
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/fiber-basics.png" width="240"/> | Fiber-based cooperative multitasking basics | [Demo](https://demo.thi.ng/umbrella/fiber-basics/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/fiber-basics) |
|
|
404
|
+
| <img src="https://raw.githubusercontent.com/thi-ng/umbrella/develop/assets/examples/ifs-fractal.jpg" width="240"/> | Barnsley fern IFS fractal renderer | [Demo](https://demo.thi.ng/umbrella/ifs-fractal/) | [Source](https://github.com/thi-ng/umbrella/tree/develop/examples/ifs-fractal) |
|
|
404
405
|
|
|
405
406
|
## API
|
|
406
407
|
|
package/fiber.js
CHANGED
|
@@ -9,7 +9,7 @@ import { EVENT_FIBER_CANCELED, EVENT_FIBER_DONE, EVENT_FIBER_ERROR, STATE_ACTIVE
|
|
|
9
9
|
let DEFAULT_ID_GEN = prefixed("fib-", monotonic());
|
|
10
10
|
export const setDefaultIDGen = (gen) => (DEFAULT_ID_GEN = gen);
|
|
11
11
|
const NO_RESULT = { done: false, value: undefined };
|
|
12
|
-
|
|
12
|
+
let Fiber = Fiber_1 = class Fiber {
|
|
13
13
|
constructor(gen, opts) {
|
|
14
14
|
this.state = STATE_NEW;
|
|
15
15
|
this.autoTerminate = false;
|
|
@@ -353,6 +353,7 @@ export let Fiber = Fiber_1 = class Fiber {
|
|
|
353
353
|
Fiber = Fiber_1 = __decorate([
|
|
354
354
|
INotifyMixin
|
|
355
355
|
], Fiber);
|
|
356
|
+
export { Fiber };
|
|
356
357
|
/**
|
|
357
358
|
* Functional syntax sugar for {@link Fiber} constructor. The `opts` are only
|
|
358
359
|
* used if given a generator or {@link FiberFactory}.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thi.ng/fibers",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.3",
|
|
4
4
|
"description": "Process hierarchies & operators for cooperative multitasking",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./index.js",
|
|
@@ -34,22 +34,22 @@
|
|
|
34
34
|
"test": "testament test"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@thi.ng/api": "^8.9.
|
|
38
|
-
"@thi.ng/arrays": "^2.5.
|
|
39
|
-
"@thi.ng/bench": "^3.4.
|
|
40
|
-
"@thi.ng/checks": "^3.4.
|
|
41
|
-
"@thi.ng/errors": "^2.3.
|
|
42
|
-
"@thi.ng/idgen": "^2.2.
|
|
43
|
-
"@thi.ng/logger": "^1.4.
|
|
44
|
-
"@thi.ng/random": "^3.6.
|
|
37
|
+
"@thi.ng/api": "^8.9.5",
|
|
38
|
+
"@thi.ng/arrays": "^2.5.22",
|
|
39
|
+
"@thi.ng/bench": "^3.4.6",
|
|
40
|
+
"@thi.ng/checks": "^3.4.5",
|
|
41
|
+
"@thi.ng/errors": "^2.3.5",
|
|
42
|
+
"@thi.ng/idgen": "^2.2.6",
|
|
43
|
+
"@thi.ng/logger": "^1.4.21",
|
|
44
|
+
"@thi.ng/random": "^3.6.4"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@microsoft/api-extractor": "^7.36.4",
|
|
48
|
-
"@thi.ng/testament": "^0.3.
|
|
48
|
+
"@thi.ng/testament": "^0.3.23",
|
|
49
49
|
"rimraf": "^5.0.1",
|
|
50
50
|
"tools": "^0.0.1",
|
|
51
|
-
"typedoc": "^0.
|
|
52
|
-
"typescript": "^5.
|
|
51
|
+
"typedoc": "^0.25.0",
|
|
52
|
+
"typescript": "^5.2.2"
|
|
53
53
|
},
|
|
54
54
|
"keywords": [
|
|
55
55
|
"blocking",
|
|
@@ -108,5 +108,5 @@
|
|
|
108
108
|
"status": "alpha",
|
|
109
109
|
"year": 2023
|
|
110
110
|
},
|
|
111
|
-
"gitHead": "
|
|
111
|
+
"gitHead": "34c3bd36b0133af05abc7fe66affa01dd99704ac\n"
|
|
112
112
|
}
|