@qxuken/kui (0.1.0-alpha.2)

Published 2026-09-02 19:40:20 +03:00 by qxuken in qxuken/kui

Installation

@qxuken:registry=
npm install @qxuken/[email protected]
"@qxuken/kui": "0.1.0-alpha.2"

About this package

kui

kui for Node: JSX views (a custom jsx-runtime, no React) lowered into the kui IR in one call per frame, Elm-style messages as data. The library itself is documented in the kui repository.

The package is published to that Forgejo's npm registry under the @qxuken scope; route the scope there once (Forgejo does not proxy npmjs, so do not override the default registry) and install:

npm config set @qxuken:registry https://drydock9.qxuken.dev/api/packages/qxuken/npm/
npm install @qxuken/kui@alpha

Or start from the template: npm create @qxuken/kui-node my-app.

The tarball bundles the native addon for linux-x64, linux-arm64, darwin-arm64, darwin-x64 and win32-x64 under prebuilds/; native.cjs picks the one matching process.platform-process.arch. On any other platform build it from the repo (cargo build -p kui-node --release) and set KUI_NODE_LIB to the resulting library.

// tsconfig: "jsx": "react-jsx", "jsxImportSource": "@qxuken/kui"
import { createApp, runWindowed } from '@qxuken/kui';

const view = (model: Model) => (
  <box pad={24} gap={16}>
    <button onClick={{ kind: 'add', by: 1 }}>+1</button>
    <text size={20}>{`count = ${model.count}`}</text>
  </box>
);
const app = createApp({ init, update, view }, { width: 640, height: 480 });   // headless
const final = await runWindowed({ init, update, view }, { title: 'counter' }); // a window
Details
npm
2026-09-02 19:40:20 +03:00
3
MIT
29 MiB
Assets (1)
Versions (33) View all
0.1.0-alpha.38 2026-10-06
0.1.0-alpha.34 2026-10-03
0.1.0-alpha.33 2026-10-02
0.1.0-alpha.32 2026-10-02
0.1.0-alpha.31 2026-10-01