Commit Graph
54 Commits
Author SHA1 Message Date
Bendik Aagaard LynghaugandClaude Fable 5 ce1ec9e4a9 rebrand: buuh — a friendly public fork under the uhhm org
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
2026-09-08 19:55:20 +02:00
Bendik Aagaard LynghaugandClaude Fable 5 99f9da1e3b feat(bankai): Phase 4 follow-ups — css convention, live titles, prerender, HTTP/2, size budget
- 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
2026-09-08 19:39:25 +02:00
Bendik Aagaard LynghaugandClaude Fable 5 8b684a17d2 feat(examples)+test(e2e): counter service worker; bankai dev+prod in Chromium
The counter example gains a sw.js exercising bankai's injected-precache
build. e2e proves both bankai paths in real Chromium: the built app
serves, hydrates and runs with zero console errors and zero mismatch
warnings (and choo consumed window.initialState), and the dev server's
Vite-transformed virtual entry hydrates the same way.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
2026-09-08 19:32:37 +02:00
Bendik Aagaard LynghaugandClaude Fable 5 d22f996596 feat(examples)+test(e2e): streaming SSR demo, proven progressive in Chromium
examples/streaming is a runnable Node server piping toStream() through
Readable.fromWeb. The e2e server gains /stream, and two tests prove real
streaming: shell bytes arrive over HTTP before the async hole resolves,
and Chromium builds the shell DOM mid-stream, then grows the slow section
into the same document without navigation.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
2026-09-08 18:44:52 +02:00
Bendik Aagaard LynghaugandClaude Fable 5 63b56144a5 test(e2e): real-browser pass in Playwright Chromium
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
2026-09-08 17:57:27 +02:00
Bendik Aagaard LynghaugandClaude Fable 5 870aa79668 test+docs: full-app browser integration test and the isomorphic counter example
The integration test runs the counter through the real browser path in
happy-dom: start(), store events, raf-batched morph, DOM click handlers,
emit coalescing. examples/counter is the Phase 2 exit criterion: one app
module mounted zero-build in a browser via import map and string-rendered
by node examples/counter/render.js.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014NgfSjHE11oFpoSnLVKLXd
2026-09-08 16:56:54 +02:00
Yoshua Wuyts 8e8e870d45 implement choo v5 API (#425)
* implement choo v5 API

* fix tests

* 5.0.0-3

* 4kb now

* bump nanomorph

* 5.0.0-4

* fix missing deps stuff

* 5.0.0-5

* fix travis

* fixup! oops standard

* chooexpose

* fix state passing

* fixup! update example

* fixup! incorporate feedback

* fixup! more docs

* fixup! even more docs
2017-03-21 03:00:45 +01:00
Haroen Viaene 6fc525fe05 update name in mailbox example (#382) 2017-02-07 14:02:59 +01:00
Yoshua Wuyts a7916ec3f9 [major] choo v4 (#352)
* location: change url on location:setLocation

- [ ] don't break hashing
- [ ] allow not changing the url

fixup! move fns around

fixup! add search string

* app.start: clean

* walk: add

* location: update arg calls

* fixup! location: update

* uri-wrap: fix thunking

* router: update to latest sheet-router (#239)

* router: update to latest sheet-router

* tests: fix for latest version

* tests: fix SSR

* tests: fix history

* tests: spruce up

* docs: update example

* examples: update

* deps: bump sheet-router

* 4.0.0-0

* chore(changelog): 4.0.0 (#211)

* feat(api:) arg order (#268)

* s/data, state/state, data/

* feat(api): swap arguments

* fix(href): fix routing (#271)

* feat(http): remove (#269)

* feat(router): enable hash routing (#273)

* deps: fix mount

* 4.0.0-1

* feat(mount): copy {script,link} tags

* 4.0.0-2

* fix(mount): forEach -> for

Lol can't use forEach

* fix(router): use state.location.href (#282)

* fix(mount): use deep node clone

* 4.0.0-3

* fix(deps): remove hash-match

* 4.0.0-4

* fix(mount): return node

* 4.0.0-5

* fix(router): check if a hash is a valid selector (#339)

* 4.0.0-6

* fix(router): pass params on newstate (#343)

* 4.0.0-7

* feat(docs): update for 4.0.0 (#320)

* feat(docs): update for 4.0.0

* docs: update router example in readme (#337)

* chore(changelog): update for v4 (#351)
2016-12-11 19:35:29 +01:00
Matt McFarland b9698a7527 Fixes for #160
- Added instructions to create the html.js file as requested per the issue.
 - Added the html.min.js file to the vanilla example
 - Tested and working as expected.
2016-08-02 10:17:59 -04:00
Chia-liang Kao 44416fdc63 Actually make scripts/test lint fail 2016-07-23 16:23:24 +08:00
Todd Kennedy 147dabfcd7 Update effects sections to latest API (#187)
They have to call done!
2016-07-21 10:16:46 -07:00
traducer fda6ee4c8f Merge branch 'master' into stopwatch 2016-07-20 20:23:19 -07:00
Juan Soto 9fb124cf1c Pluralize "times" correctly 2016-07-15 09:22:26 -04:00
Juan Soto 17959b8105 Add async-counter example 2016-07-15 09:22:25 -04:00
Brad Simantel dbe41b9793 Add pathname-match dependency to mailbox example
The pathname-match module is being required in the pathname element, but wasn't actually included as a dependency.
2016-07-15 09:22:25 -04:00
traducer c412b9604a xtend not needed, removed 2016-07-13 23:54:29 +00:00
traducer 5f858cfdf5 added stopwatch example
added requestAnimationFrame polyfill

moved raf logic into a subscription

separated logic into multiple files, all state lives in a global namespaced model, reset no longer sends multiple actions only one
2016-07-13 16:59:20 +00:00
Boris Serdiuk c03bcd21e5 prepare umd build before publish 2016-07-12 15:27:42 +02:00
Brad Simantel d9a14130b3 Add pathname-match dependency to mailbox example
The pathname-match module is being required in the pathname element, but wasn't actually included as a dependency.
2016-07-06 14:35:46 -07:00
Yoshua Wuyts 4ad3dc9b72 deps: bump to barracks 8 2016-07-05 17:55:17 +02:00
timwis d19e67322a Rename action param -> data in examples 2016-07-03 12:37:43 -04:00
Yoshua Wuyts 6407188ee9 router: change order of arguments
fixup! freeze state & rename app ns to location
2016-07-02 22:54:35 +02:00
Yoshua Wuyts 9e039ed561 architecture: use barracks
Changes
=======
- add hook handlers
- add effect composition
- add noFreeze option

Commits
=======
- fixup! fix toString()
- fixup! use assert instead of throw
- fixup! fix reducers
- fixup! work on done callbacks
- fixup! more callback work
- fixup! woooh fixed effects errs
- fixup! wrap up stuff
2016-07-02 16:00:26 +02:00
Todd Kennedy 8f8df602c5 Extract html into separate module (#103) 2016-07-02 12:55:41 +02:00
Yoshua Wuyts 47cc4f8c2c Merge pull request #73 from zigomir/fix-mailbox-example
Fix mailbox example
2016-06-30 16:15:06 +02:00
Mattijs Bliek 25926d0667 Fix typo in view 2016-06-23 11:34:27 +02:00
zigomir 51a9c4488e Fix full reload on specific message. 2016-06-22 17:39:13 -07:00
zigomir cf1548e61d Add tachyons dependency. 2016-06-22 17:38:55 -07:00
Yoshua Wuyts 9486df4725 examples: add sse 2016-06-20 23:51:29 +01:00
John Otander ec81364906 Fix typo in server rendering view 2016-06-18 18:55:12 -06:00
Yoshua Wuyts 918417f575 Merge pull request #14 from markmontymark/patch-1
Update nav.js, removing duplicated, unused fn arg
2016-05-24 03:17:53 +09:00
Yoshua Wuyts 60665f2a71 toString: support rehydration 2016-05-24 02:10:17 +09:00
Mark bc7b6a209c Update nav.js, removing duplicated, unused fn arg 2016-05-23 09:15:59 -07:00
Yoshua Wuyts ab96d51a89 examples/server -> examples/server-rendering 2016-05-23 14:45:24 +09:00
Yoshua Wuyts dc840059a4 models: fix state namespace 2016-05-23 14:40:52 +09:00
Yoshua Wuyts 0cc0caa8e1 examples/http: update for ns 2016-05-23 13:44:32 +09:00
Yoshua Wuyts 300b6325a9 examples: update mailbox 2016-05-23 04:00:29 +09:00
Yoshua Wuyts 24b9be7c8d models: sturdify namespaces 2016-05-23 03:32:14 +09:00
Yoshua Wuyts 46eabb02ae examples: fix mailbox 2016-05-22 16:56:24 +09:00
Yoshua Wuyts 4084775c8c choo: add server rendering 2016-05-22 02:06:46 +09:00
Yoshua Wuyts 620fe35426 deps: bump sheet-router 2016-05-21 15:32:01 +09:00
Yoshua Wuyts 6eef04663d docs: setup example section 2016-05-16 02:48:47 +07:00
Yoshua Wuyts 1481cb0f6c example-mailbox: v6 2016-05-14 10:44:44 +07:00
Yoshua Wuyts 32ae62d655 example-mailbox: v5 2016-05-13 16:48:46 +07:00
Yoshua Wuyts 4757e791f9 http: add 2016-05-13 12:24:51 +07:00
Yoshua Wuyts 56f335b71d example-mailbox: v4 2016-05-12 19:37:02 +07:00
Yoshua Wuyts 5219fbafca example-mailbox: v3 2016-05-12 19:33:52 +07:00
Yoshua Wuyts 94e8073af1 examples/http -> examples/mailbox 2016-05-12 15:44:33 +07:00
Yoshua Wuyts 1d14f9f26b example-mailbox: v2 2016-05-12 15:42:44 +07:00