stillflow.engine 0.4.0 → 0.4.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/README.md CHANGED
@@ -53,7 +53,7 @@ You can test some benchmarks on [**CodeSandBox**](https://codesandbox.io/p/sandb
53
53
  | **Lazy remove every 2nd row** | 10,000 rows (60k removed) | **~242ms max** ($O(k \log n)$ scaling) |
54
54
 
55
55
  ```ts
56
- import { Stillflow, State, collection, operators, adapters } from 'stillflow.engine'
56
+ import { core, vm, collection, operators, adapters } from 'stillflow.engine'
57
57
 
58
58
  type AppState = {
59
59
  input: string
@@ -70,8 +70,8 @@ type TodoState = {
70
70
 
71
71
  const { jsxdom, dom } = adapters
72
72
 
73
- const state = new State()
74
- const stillflow = new Stillflow<AppState>(state)
73
+ const state = new core.State()
74
+ const stillflow = new core.Stillflow<AppState>(state)
75
75
  const factory = stillflow.factory()
76
76
 
77
77
  factory.add(collection.Flushable.name, () => new collection.Flushable(new collection.Fenwick(100)))
@@ -1,8 +1,7 @@
1
- import { core, vm, collection, operators, adapters } from '../index.js';
2
- const { Stillflow, State, Batcher } = core;
1
+ import { core, vm, collection, operators, adapters } from 'stillflow.engine';
3
2
  const { jsxdom, dom } = adapters;
4
- const state = new State();
5
- const stillflow = new Stillflow(state);
3
+ const state = new core.State();
4
+ const stillflow = new core.Stillflow(state);
6
5
  const factory = stillflow.factory();
7
6
  factory.add(collection.Flushable.name, () => new collection.Flushable(new collection.Fenwick(100)));
8
7
  const source = {
@@ -29,9 +28,7 @@ function App() {
29
28
  vm.jsx(jsxdom.button, { "on:click": add }, "Add"),
30
29
  vm.jsx(jsxdom.div, { "sf:for": (context) => context.items, "sf:each": () => vm.jsx(TodoItem, null) })));
31
30
  }
32
- const update = dom.$(vm.jsx(App, null), {
33
- container: document.body
34
- });
31
+ const update = dom.$(vm.jsx(App, null), { container: document.body });
35
32
  stillflow.on(() => update(instance));
36
33
  instance.input = String();
37
34
  stillflow.commit();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "stillflow.engine",
3
- "version": "0.4.0",
3
+ "version": "0.4.1",
4
4
  "description": "A headless, transaction-based UI engine with AOT compilation.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",