Node 24's test runner spawns directory arguments as entry modules
(MODULE_NOT_FOUND); Node 26 accepts them. Shell-expanded file globs work
on both — found by the first real CI run on the Gitea runner, where the
Node 24 matrix leg and the release gate failed while 26 passed.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
Packages renamed to the @uhhm scope (@uhhm/buuh, @uhhm/buuh-html,
@uhhm/buuh-component, @uhhm/buuh-devtools, @uhhm/buuh-migrate,
@uhhm/bankai). Scoping is load-bearing twice over: npm routes registries
per scope so @uhhm/* resolves against project.uhhm.no while everything
else stays on npmjs, and it means this fork never squats upstream's
names anywhere. The codemod now migrates choo v7 apps to the @uhhm
names. README rewritten with the fork framing and full upstream credit;
the choojs RFC moves to docs/upstream-rfc-draft.md, in the drawer for if
this work ever goes home. API unchanged — choo() is still choo().
Also: Gitea Actions CI + release workflows (npm publish to the uhhm
registry on tag push, CDN bundle uploaded as a generic package),
npm run bundle producing dist-cdn/buuh.js (the whole framework as one
minified ES module for import-map use), docs/publishing.md explaining
what Gitea Packages is (a real npm registry) and is not (a CDN — serve
the bundle from a static host with module-safe MIME instead), and
onload.js constructing window.MutationObserver to match its own guard
(surfaced by smoke-testing the bundle outside a full browser).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
- style.css convention: <entry dir>/style.css is imported by the virtual
client entry (CSS is a client concern; server code never sees it — the
v8 answer to sheetify), extracted and hashed by Vite, stylesheet-linked
in the head and preloaded via Early Hints. Counter example styled.
- SSR <title> from state: the server reads the first stream chunk before
writing the head, by which point stores and the first render slice have
run — DOMTitleChange emits land in the document title. Counter emits.
- bankai build --prerender /,/about renders routes through the same
toStream path to static <route>/index.html (precompressed, precached
by the service worker, served with Early Hints).
- bankai serve --h2: HTTP/2 with a generated local cert (openssl,
cached; allowHTTP1) — browsers only act on Early Hints over h2/h3.
Tested with a real h2 client observing the 103 interim response.
- npm run size: the framework wire-size budget, enforced in CI. Whole
framework (core + html engine + morph + hydrate) is 7.97 kB min+gzip /
7.15 kB brotli; budget 8.5 kB with the v7 '4kb' context documented
(that number excluded the html engine, which lived in the browserify
transform).
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
One command, zero config, and only the client ever bundles: v8 server
code is plain ESM that Node runs as-authored, so there is no server
build to rot (the lesson of v9).
- start: Vite middleware mode + HMR with per-request streaming SSR via
ssrLoadModule; a virtual client entry generates the browser glue so
the user writes exactly one isomorphic module (plan decision D5).
- build: client bundle via Vite 8/Rolldown, manifest-derived route
assets in dist/bankai.json, service worker built with the precache
list injected (choo-service-worker convention, manifest edition),
brotli+gzip precompression of every text asset.
- serve: immutable caching + precompressed negotiation for hashed
assets, 103 Early Hints (res.writeEarlyHints) with the route's assets
before every page, streaming SSR, and a window.initialState tail with
script-breakout-safe serialization and choo internals filtered out.
- inspect: raw/gzip/brotli size report.
Integration tests drive the real counter example through build and
serve, asserting the 103 interim response at the HTTP level.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
Carries forward the choo-devtools 3.x essentials: live state handle,
emit-from-console, event log, nanotiming measures via PerformanceObserver,
state copy(), help(). No-op on the server; verbose logging opt-in via
localStorage.CHOO_DEVTOOLS_VERBOSE.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
npm run bench (happy-dom, all three engines) and npm run bench:browser
(Playwright Chromium, the two ESM engines). Honest numbers recorded in
docs/v8.md: we create ~12% faster than µhtml in real Chromium (the
parse-once/clone design), µhtml updates in place ~5x faster than
fresh-tree + nanomorph (choo's architectural cost, mitigated by component
caching), and server strings are on par with nanohtml v1.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
Three end-to-end scenarios against a static+SSR test server: the
zero-build page (import map + native ESM, no bundler), the SSR page
(rendered content in the raw response, live after hydration, no mismatch
warnings), and adoption (an expando on the server-rendered node survives
a real render). Renders are raf-batched so assertions poll.
Real Chromium flushed out three fixes happy-dom couldn't see:
- nanoraf called an extracted requestAnimationFrame bare — Illegal
invocation under strict-mode ESM (sloppy CJS had masked it); wrapped.
- the counter example only routed '/', so serving it from any subpath
threw; it now has a wildcard fallback.
- hydration mismatch detection is now whitespace-insensitive (the parser
reparents whitespace, e.g. text after </body>), and page scripts belong
in <head> when a view owns <body> — same convention bankai v9 used.
CI gets an e2e job with chromium-headless-shell.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
Each template literal parses once, keyed by its strings array in a
WeakMap: static parts become a <template> with hole markers, renders
clone and fill. Interpolated values never pass through innerHTML (child
values become text nodes or adopted DOM; attributes go through
setAttribute). Event handlers set as properties so nanomorph copies them.
Document-level roots (<body>/<head>/<html>) parse via DOMParser because
<template> drops them. Replaces the v7 browserify transform entirely —
production speed is now a runtime property.
Tests run in happy-dom (new devDependency), including a check that server
and browser renderers serialize identical markup.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
As described by #563:
> https://polyfill.io provides a fallback for browsers that don't support it, so for most people this will be a strict improvement.
`discify` is a different module than intended. discify is an alternative
to disc that works as a plugin, but we were using it as a separate
command line program. This switches it out for disc. The disc command
line program is called `discify` which is probably where the confusion
came from.
Also swapped out unassertify and uglifyify for tinyify, which adds tree
shaking.