{"id":50594845,"url":"https://github.com/fponticelli/llui","last_synced_at":"2026-06-05T13:02:06.615Z","repository":{"id":349868187,"uuid":"1198897700","full_name":"fponticelli/llui","owner":"fponticelli","description":"The LLM first UI framework ","archived":false,"fork":false,"pushed_at":"2026-05-30T04:26:24.000Z","size":8585,"stargazers_count":7,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-30T06:14:54.440Z","etag":null,"topics":["framework","frontend","typescript","ui","web"],"latest_commit_sha":null,"homepage":"https://llui.dev/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fponticelli.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-01T21:39:43.000Z","updated_at":"2026-05-30T04:26:28.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/fponticelli/llui","commit_stats":null,"previous_names":["fponticelli/llui"],"tags_count":105,"template":false,"template_full_name":null,"purl":"pkg:github/fponticelli/llui","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fponticelli%2Fllui","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fponticelli%2Fllui/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fponticelli%2Fllui/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fponticelli%2Fllui/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fponticelli","download_url":"https://codeload.github.com/fponticelli/llui/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fponticelli%2Fllui/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33942436,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-05T02:00:06.157Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["framework","frontend","typescript","ui","web"],"created_at":"2026-06-05T13:02:05.932Z","updated_at":"2026-06-05T13:02:06.607Z","avatar_url":"https://github.com/fponticelli.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LLui\n\nA compile-time-optimized web framework built on [The Elm Architecture](https://guide.elm-lang.org/architecture/), designed for LLM-first authoring.\n\n**No virtual DOM. Effects as data. Compile-time bitmask optimization.**\n\n```typescript\nimport { component, mountApp, div, button } from '@llui/dom'\n\ntype State = { count: number }\ntype Msg = { type: 'inc' } | { type: 'dec' }\n\nconst Counter = component\u003cState, Msg, never\u003e({\n  name: 'Counter',\n  init: () =\u003e [{ count: 0 }, []],\n  update: (state, msg) =\u003e {\n    switch (msg.type) {\n      case 'inc':\n        return [{ ...state, count: state.count + 1 }, []]\n      case 'dec':\n        return [{ ...state, count: state.count - 1 }, []]\n    }\n  },\n  view: ({ send, text }) =\u003e [\n    div({ class: 'counter' }, [\n      button({ onClick: () =\u003e send({ type: 'dec' }) }, [text('-')]),\n      text((s) =\u003e String(s.count)),\n      button({ onClick: () =\u003e send({ type: 'inc' }) }, [text('+')]),\n    ]),\n  ],\n})\n\nmountApp(document.getElementById('app')!, Counter)\n```\n\n## Key Ideas\n\n- **`view()` runs once.** No re-rendering. DOM nodes are created at mount time with reactive bindings that update surgically when state changes. Everything you build (`el`/`text`/`each`/`show`/`branch`/…) is a lazy `Mountable`, materialized where it's placed.\n- **Chunked-mask reactivity.** Each binding carries a sparse mask of the dependency-path chunks it reads; on update the runtime computes the dirty chunk-set from old→new state and commits only the bindings whose mask intersects it. No path ceiling. Structural primitives (`branch`, `each`, `show`) reconcile arms/keyed rows and own child scopes.\n- **Effects as data.** `update()` is pure — side effects are plain objects returned alongside state, dispatched by the runtime. Testable with `deepEqual`.\n- **Compiler optimization.** The Vite plugin runs the signal transform — lowering signal expressions in a component's view to runtime helpers and surfacing the framework lint rules as non-bypassable build errors. Dependency paths are derived statically from the signal reads.\n\n## Packages\n\n| Package                                                           | Description                                                                                         |\n| ----------------------------------------------------------------- | --------------------------------------------------------------------------------------------------- |\n| [`@llui/dom`](packages/dom)                                       | Runtime — component, mount, scope tree, bindings, structural primitives, HTML/SVG/MathML helpers    |\n| [`@llui/compiler`](packages/compiler)                             | Engine — 3-pass TypeScript transform + 41 compile-time lint rules (all error severity)              |\n| [`@llui/vite-plugin`](packages/vite-plugin)                       | Vite adapter — wires the compiler into Vite, surfaces diagnostics via `this.error()`                |\n| [`@llui/compiler-introspection`](packages/compiler-introspection) | Opt-in compiler module — agent schemas, msg annotations, schema hash emission                       |\n| [`@llui/compiler-devtools`](packages/compiler-devtools)           | Opt-in compiler module — `__componentMeta` emission for source navigation                           |\n| [`@llui/compiler-ssr`](packages/compiler-ssr)                     | Opt-in compiler module — `'use client'` directive handling and SSR emission                         |\n| [`@llui/effects`](packages/effects)                               | Effect system — http, cancel, debounce, sequence, race + `Async\u003cT,E\u003e`, `ApiError`                   |\n| [`@llui/router`](packages/router)                                 | Routing — structured path matching, history/hash mode, link helper                                  |\n| [`@llui/transitions`](packages/transitions)                       | Animation helpers for `branch`/`show`/`each` — `transition()`, `fade`, `slide`, `scale`, `collapse` |\n| [`@llui/components`](packages/components)                         | 58 headless components + locale i18n + format utilities + Standard Schema forms + opt-in theme      |\n| [`@llui/test`](packages/test)                                     | Test harness — testComponent, testView, propertyTest, replayTrace                                   |\n| [`@llui/vike`](packages/vike)                                     | Vike SSR adapter — onRenderHtml, onRenderClient                                                     |\n| [`@llui/mcp`](packages/mcp)                                       | MCP server — LLM debug tools via Model Context Protocol                                             |\n| [`@llui/agent`](packages/agent)                                   | LAP server + browser client runtime for driving LLui apps from LLM clients                          |\n| [`llui-agent`](packages/agent-bridge)                             | MCP CLI bridging Claude / other LLM clients to a running `@llui/agent` server                       |\n\n## Quick Start\n\n```bash\n# Create a new project\nmkdir my-app \u0026\u0026 cd my-app\nnpm init -y\nnpm install @llui/dom @llui/effects\nnpm install -D @llui/vite-plugin vite typescript\n\n# Create vite.config.ts\ncat \u003e vite.config.ts \u003c\u003c 'EOF'\nimport { defineConfig } from 'vite'\nimport llui from '@llui/vite-plugin'\nexport default defineConfig({ plugins: [llui()] })\nEOF\n\n# Create index.html\ncat \u003e index.html \u003c\u003c 'EOF'\n\u003c!DOCTYPE html\u003e\n\u003chtml\u003e\u003cbody\u003e\u003cdiv id=\"app\"\u003e\u003c/div\u003e\u003cscript type=\"module\" src=\"/src/main.ts\"\u003e\u003c/script\u003e\u003c/body\u003e\u003c/html\u003e\nEOF\n\n# Create src/main.ts with your component\nnpx vite\n```\n\n## Documentation\n\n- [Getting Started](docs/getting-started.md) — first component, project setup, basic patterns\n- [Cookbook](docs/cookbook.md) — forms, async, lists, routing, composition, SSR\n- [Design Documents](docs/designs/) — architecture, compiler, runtime, performance\n- [API Reference](docs/designs/09%20API%20Reference.md) — type signatures for all exports\n\n## Development\n\n```bash\npnpm install\npnpm turbo build          # Build all packages\npnpm turbo test           # Run 1200+ tests across all packages\npnpm turbo check          # Type-check\npnpm turbo lint           # ESLint\npnpm bench:setup          # One-time: clone + compile js-framework-benchmark\npnpm bench                # Run LLui benchmark (add --save to update baseline)\n```\n\n## Performance\n\nTop-tier on [js-framework-benchmark](https://github.com/krausest/js-framework-benchmark) (krausest), and **leading the framework field on fine-grained streaming updates** (a custom \"ticker\" suite). Median of 5 runs, same machine.\n\n**Standard suite** — within a few percent of Solid/Svelte; fastest on Select:\n\n| Operation     |      LLui |   Solid |  Svelte | vanilla |\n| ------------- | --------: | ------: | ------: | ------: |\n| Create 1k     |    21.6ms |  20.7ms |  20.9ms |  20.1ms |\n| Replace 1k    |    23.8ms |  23.1ms |  23.7ms |  21.7ms |\n| Update 10th   |    11.6ms |  11.4ms |  12.0ms |  10.8ms |\n| Select        | **2.7ms** |   3.4ms |   5.0ms |   2.7ms |\n| Swap          |    14.4ms |  14.0ms |  14.0ms |  12.4ms |\n| Remove        |    10.8ms |  10.2ms |  10.3ms |   9.7ms |\n| Create 10k    |   227.9ms | 216.8ms | 218.6ms | 200.0ms |\n| Append 1k     |    26.1ms |  23.5ms |  23.5ms |  23.1ms |\n| Clear         |    10.3ms |  11.0ms |  10.7ms |   8.9ms |\n| Bundle (gzip) |    8.2 KB |  4.5 KB | 12.2 KB |  2.5 KB |\n\n**Ticker suite** (streaming partial-list updates) — LLui beats every other framework on every op; trails only hand-written vanilla on bulk construction:\n\n| Operation             |       LLui |  Solid | Svelte |  React | vanilla |\n| --------------------- | ---------: | -----: | -----: | -----: | ------: |\n| Mount 200             |  **5.6ms** |  6.1ms |  6.5ms |  5.8ms |   5.8ms |\n| 100 ticks             |  **4.8ms** |  5.5ms |  5.8ms |  9.3ms |   4.0ms |\n| Burst 1k              | **15.9ms** | 21.8ms | 24.5ms | 52.6ms |   9.5ms |\n| Toggle mode (fan-out) |  **3.2ms** |  3.2ms |  3.4ms |  3.6ms |   3.1ms |\n| Churn 50              |  **4.2ms** |  4.4ms |  4.7ms |  4.4ms |   4.0ms |\n| Clear                 |  **1.1ms** |  1.2ms |  1.3ms |  1.3ms |   1.2ms |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffponticelli%2Fllui","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffponticelli%2Fllui","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffponticelli%2Fllui/lists"}