docs(requirements): tighten runtime rows
Add explicit northstar ring fields to runtime requirements and split EffectBatch application from the tiny-runtime size target without changing behavior. req: runtime/001 req: runtime/002 req: runtime/003 req: runtime/004 req: runtime/005 req: runtime/006
This commit is contained in:
@@ -64,7 +64,7 @@ Keep it stable. Prefer pointers to canonical sources over copied structure, file
|
||||
- The public component-reuse explanation lives in `docs/recipes/reusable-partials.md`; do not grow a client component framework to explain partial composition.
|
||||
- The stable public `.heml` authoring surface lives in `docs/hemplate-syntax.md`; Hemlate examples must use that real hemplate syntax, not Vue/Handlebars sketches. hemx-build consumes hemplate Surface facts and must not grow an independent `.heml` parser or CSS-path identity model. Generated resources, form/handle metadata, atoms, and event constants come from hemx-build facts, not hand-written app plumbing. Forms remain HTML-shaped, checked against user-authored Rust domain types, parsed through `FormValue`, and manipulated through generated form/control ids rather than selectors. req: surface/001 req: surface/002 req: surface/003 req: surface/004 req: surface/005 req: surface/006 req: surface/007 req: surface/008 req: surface/009 req: surface/010 req: codegen/001 req: codegen/003 req: codegen/004 req: codegen/005 req: codegen/006 req: form/001 req: form/004 req: form/007 req: form/008 req: form_effects/001 req: form_effects/002 req: form_effects/003
|
||||
- Optional `.heml` editor overlays must share authority with `hemx-build` diagnostics and `docs/hemplate-syntax.md`; `hemx-lsp` owns editor protocol glue for diagnostics/completion/hover and derive-known template facts, while VS Code/Cursor/Neovim keep normal HTML/tree-sitter tooling. Do not create a second template language, selector model, formatter, Rust type system, or custom editor framework. req: diagnostics/004 req: diagnostics/005 req: diagnostics/006
|
||||
- JS runtime changes must preserve root-scoped lookup, fail-closed request handling, root-scoped error outlets, and tiny pending/failure/trigger-timing conventions without selectors, VDOM, expressions, or per-node listeners. req: runtime/005 req: convention/001 req: convention/003 req: convention/005 req: convention/007
|
||||
- JS runtime changes must preserve root-scoped lookup, delegated listeners, postcard EffectBatch application, fail-closed request handling, root-scoped error outlets, and tiny pending/failure/trigger-timing conventions without selectors, VDOM, expressions, or per-node listeners. req: runtime/001 req: runtime/002 req: runtime/003 req: runtime/005 req: runtime/006 req: convention/001 req: convention/003 req: convention/005 req: convention/007
|
||||
- Opaque island JavaScript is a leaf adapter for high-frequency local behavior only; it must not introduce a component runtime, client state graph, VDOM, or second UI model. req: canonical_authoring/017
|
||||
- Host capability adapters must stay at the `hemx-host` boundary: they may call host APIs and return host events, but they must not mutate DOM or own app/domain state. req: host/002
|
||||
- Local/offline app behavior should be commands/events/projections; do not add `hemx-local`, stored DOM patches, stored `EffectBatch` truth, or a core client state graph without a proven reusable contract. req: canonical_authoring/018 req: canonical_authoring/019 req: local/001 req: local/002
|
||||
|
||||
+8
-5
@@ -526,19 +526,22 @@ what a valid business email is. [north_star]
|
||||
## runtime
|
||||
|
||||
### req: runtime/001
|
||||
001 Every hemx tree must declare a root boundary via `data-hemx-root` on an ancestor element. The JS runtime resolves lookups within that root only. Multiple independent hemx apps/widgets/modals may coexist on the same document without ID collision. [north_star]
|
||||
0 001 Every hemx tree declares a root boundary via `data-hemx-root`. JS runtime lookups stay within that root, so independent hemx apps/widgets/modals can coexist without ID collision. [north_star]
|
||||
|
||||
### req: runtime/002
|
||||
002 JS runtime attaches a single delegated listener per event type on each `data-hemx-root`. No per-node listeners. Dispatch resolves target via `data-hid` / `data-sid` attributes on the event path scoped to its root.
|
||||
0 002 JS runtime attaches a single delegated listener per event type on each `data-hemx-root`. No per-node listeners. Dispatch resolves target via `data-hid` / `data-sid` attributes on the event path scoped to its root. [north_star]
|
||||
|
||||
### req: runtime/003
|
||||
003 The core JS runtime target is under 5KB minified+gzipped. It remains a tiny op interpreter (no selectors, no VDOM, no scheduler, no expressions). It reads postcard `EffectBatch` bytes and applies them as DOM operations. Optional sync/transition/WASM helpers are separate files.
|
||||
0 003 The core JS runtime target is under 5KB minified+gzipped. It remains a tiny op interpreter: no selectors, VDOM, scheduler, or expressions. [north_star]
|
||||
|
||||
### req: runtime/006
|
||||
0 006 The core JS runtime reads postcard `EffectBatch` bytes and applies them as DOM operations. Optional sync/transition/WASM helpers are separate files. [north_star]
|
||||
|
||||
### req: runtime/004
|
||||
004 Core runtime exposes a minimal version/fingerprint handshake only. Capability negotiation belongs to integration crates such as `hemx-wasm`, `hemx-sync`, and `hemx-transition`.
|
||||
0 004 Core runtime exposes a minimal version/fingerprint handshake only. Capability negotiation belongs to integration crates such as `hemx-wasm`, `hemx-sync`, and `hemx-transition`. [north_star]
|
||||
|
||||
### req: runtime/005
|
||||
005 Failed hemx HTTP requests must fail closed: non-2xx responses are not applied as effects, pending state is restored, root-scoped `data-hemx-error` outlets show a transport failure when present, and the runtime emits an inspectable `hemx:error` event with status when available. [north_star]
|
||||
0 005 Failed hemx HTTP requests fail closed: non-2xx responses are not applied as effects, pending state is restored, root-scoped `data-hemx-error` outlets show transport failure, and runtime emits `hemx:error` with status when available. [north_star]
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user