Skip to content

docs(demo): add the library-comparison counter demo - #70

Merged
ayo-run merged 3 commits into
mainfrom
claude/counter-demo-implementations-b1k225
Jul 22, 2026
Merged

docs(demo): add the library-comparison counter demo#70
ayo-run merged 3 commits into
mainfrom
claude/counter-demo-implementations-b1k225

Conversation

@ayo-run

@ayo-run ayo-run commented Jul 22, 2026

Copy link
Copy Markdown
Owner

The comparison guide cites a counter measured in each library but the
implementations lived nowhere in the repo. Add them, plus the benchmark
that produces the guide's numbers, as a runnable demo example, and link
the guide to it.

  • demo/examples/library-comparison/counters/*.mjs — the same minimal
    counter (one reactive count prop, click handler, re-render) in
    web-component-base, Elena, Lit, FAST, and vanilla HTMLElement.
  • index.html — all five running live side by side, with the methodology
    and the measured output table.
  • measure.mjs — bundles each counter with its library runtime (esbuild
    --bundle --minify --format=esm) and compresses with gzip (-9) / brotli
    (q11) via Node zlib; reproduces the guide's numbers deterministically.
  • Pin the three external libraries as demo devDependencies so the live
    demo and the benchmark resolve the same sources.
  • Link the demo from the comparison guide and add a landing-page card.

claude added 3 commits July 22, 2026 21:19
The comparison guide cites a counter measured in each library but the
implementations lived nowhere in the repo. Add them, plus the benchmark
that produces the guide's numbers, as a runnable demo example, and link
the guide to it.

- demo/examples/library-comparison/counters/*.mjs — the same minimal
  counter (one reactive `count` prop, click handler, re-render) in
  web-component-base, Elena, Lit, FAST, and vanilla HTMLElement.
- index.html — all five running live side by side, with the methodology
  and the measured output table.
- measure.mjs — bundles each counter with its library runtime (esbuild
  --bundle --minify --format=esm) and compresses with gzip (-9) / brotli
  (q11) via Node zlib; reproduces the guide's numbers deterministically.
- Pin the three external libraries as demo devDependencies so the live
  demo and the benchmark resolve the same sources.
- Link the demo from the comparison guide and add a landing-page card.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TwF7mbKVnL14rJBLH3Jo71
…nter

Every counter in this comparison needs JS to be reactive, so the marketing
phrase was misleading. Describe what the code actually does instead: Elena's
`html` has no inline event syntax, so the click handler is attached in
`firstUpdated`.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TwF7mbKVnL14rJBLH3Jo71
The comparison table described competitors with non-technical positioning
language rather than facts. Make each neutral and column-appropriate:

- Elena SSR: "HTML/CSS-first" -> "server-rendered markup + hydration
  utilities" (the slogan implied pre-JS behavior).
- Lit backing: "huge ecosystem" -> "large ecosystem".
- Elena backing: "design-system focus" (a use-case slogan that didn't
  answer the Backing/ecosystem column) -> "solo-authored".
- WebC note: drop the editorializing "and solves it well".

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TwF7mbKVnL14rJBLH3Jo71
@netlify

netlify Bot commented Jul 22, 2026

Copy link
Copy Markdown

Deploy Preview for demo-wcb ready!

Name Link
🔨 Latest commit 2a20bf2
🔍 Latest deploy log https://app.netlify.com/projects/demo-wcb/deploys/6a6138edb490800008bb72d2
😎 Deploy Preview https://deploy-preview-70--demo-wcb.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@netlify

netlify Bot commented Jul 22, 2026

Copy link
Copy Markdown

Deploy Preview for web-component-io ready!

Name Link
🔨 Latest commit 2a20bf2
🔍 Latest deploy log https://app.netlify.com/projects/web-component-io/deploys/6a6138edd94c5b000853ac74
😎 Deploy Preview https://deploy-preview-70--web-component-io.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@ayo-run
ayo-run merged commit 005db54 into main Jul 22, 2026
9 of 10 checks passed
@ayo-run
ayo-run deleted the claude/counter-demo-implementations-b1k225 branch July 25, 2026 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants