@cyberstrike-io/tui-core
v0.1.75
Published
CyberstrikeTUI is a TypeScript library for building terminal user interfaces (TUIs)
Readme
@cyberstrike/tui-core
Cyberstrike TUI Core is a TypeScript library for building terminal user interfaces (TUIs). It is currently in development and is not ready for production use.
Documentation
- Getting Started - API and usage guide
- Development Guide - Building, testing, and contributing
- Tree-Sitter - Syntax highlighting integration
- Renderables vs Constructs - Understanding the component model
- Environment Variables - Configuration options
Install
bun install @cyberstrike/tui-coreBuild
bun run buildThis creates platform-specific libraries that are automatically loaded by the TypeScript layer.
Examples
bun install
bun run src/examples/index.tsBenchmarks
Run native performance benchmarks:
bun run bench:nativeSee src/zig/bench.zig for available options like --filter and --mem.
CLI Renderer
Renderables
Renderables are hierarchical objects that can be positioned, nested, styled and rendered to the terminal:
import { createCliRenderer, TextRenderable } from "@cyberstrike/tui-core"
const renderer = await createCliRenderer()
const obj = new TextRenderable(renderer, { id: "my-obj", content: "Hello, world!" })
renderer.root.add(obj)