@tinyactors/wasm 0.3.0 → 0.4.0

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/README.md CHANGED
@@ -18,10 +18,9 @@ const compiled = compileCharts([{ name: 'hello.scxml', text: `
18
18
  datamodel="ecmascript" name="hello" initial="s">
19
19
  <state id="s"><onentry><log expr="'hello from ' + _ioprocessors.scxml.location"/></onentry></state>
20
20
  </scxml>` }]);
21
- const host = new Host({ systemID: 'web' }, { log: (host, entry) => console.log(entry.text) });
22
- host.addImage(compiled.image);
21
+ const host = new Host(compiled, { system: 'web', log: (entry) => console.log(entry.text) });
23
22
  compiled.close();
24
- host.spawn(host.chart('hello'));
23
+ host.spawn('hello');
25
24
  await host.idle();
26
25
  host.close();
27
26
  ```
@@ -66,9 +65,19 @@ The guides are shared with `@tinyactors/node`:
66
65
  - [@tinyactors/node's README](https://github.com/tinyactors-dev/tinyactors-napi#readme):
67
66
  the concepts, from a first chart to hosts, actors, I/O processors and
68
67
  errors.
69
- - [The guides](https://github.com/tinyactors-dev/tinyactors-napi/tree/main/docs/guide):
70
- charts, I/O processors, services, other systems, hibernation,
71
- migration, snapshots, telemetry, inspection, capacity and testing.
68
+ - [The guides](https://github.com/tinyactors-dev/tinyactors-napi/tree/main/docs/guide),
69
+ in three groups, as the README orders them:
70
+ - **writing an application:** charts, I/O processors, when the actor
71
+ is not there, services, hibernation with a store, testing, the
72
+ quickjs sandbox;
73
+ - **operating a host** (the README's
74
+ [Operating a host](https://github.com/tinyactors-dev/tinyactors-napi#operating-a-host)):
75
+ inspection, capacity, telemetry, hibernation by a policy of your own,
76
+ migration, snapshots;
77
+ - **the wire format** (the README's
78
+ [Wire format](https://github.com/tinyactors-dev/tinyactors-napi#wire-format)):
79
+ `encode` and `decode`, `decodeTraces`, addresses, other systems and
80
+ SCXML's BasicHTTP.
72
81
 
73
82
  Charts are trusted code: their expressions run as JavaScript in a realm
74
83
  of their own, which is not a security boundary.