What is Gridland?
mainGridland is a UI framework that allows you to render the same React component tree to multiple environments: a browser canvas, a terminal (TUI), or plain text for AI agents.
Key characteristics:
- Dual Runtimes: Use
@gridland/webto draw components to an HTML5<canvas>in a browser, or@gridland/bunto draw them tostdoutin a terminal via a native FFI bridge. - Agent-Friendly: Components can render to plain text, making TUIs natively readable by LLMs, crawlers, and screen readers without a separate accessibility layer.
- Component Ownership: Gridland uses a distribution model similar to
shadcn/ui. Instead of installing a monolithic package, you add component source code directly to your project using the CLI, allowing for full customization. - Cell-Based Layout: Layouts are sized in character cells rather than pixels, ensuring perfect alignment across different terminal widths and font sizes. It uses the Yoga engine for Flexbox layout.