zion-off/giggles: batteries-included react framework for building rich terminal apps

🚀 Discover this insightful post from Hacker News 📖

📂 **Category**:

📌 **What You’ll Learn**:

CI
CD
docs

giggles

giggles is a batteries-included react framework for building terminal apps. built on ink, it handles focus, input routing, screen navigation, and theming out of the box so you can skip the plumbing and build.

inspired by the charmbracelet ecosystem, it comes with a rich set of UI components, hooks for focus and navigation management, and terminal utilities for things like running shell commands.

  • each component owns its keys — a text input inside a list inside a panel all work independently, with unhandled keys naturally passing up to the right parent. no global input handler, no coordination code
  • navigate between views with a simple API; the previously focused component is restored when you return
  • a full set of hooks and components — useFocusScope, useFocusNode, FocusTrap, useNavigation, and more — for building any interaction pattern without reimplementing the plumbing
  • built-in keybinding registry so your app can always show users what keys do what, in the current context — context-aware and accessible via a hook
  • a component library covering most TUI use cases, from text inputs and autocomplete to virtual lists for large datasets — with sensible defaults and render props for full customization
  • render markdown in the terminal, with full formatting and syntax-highlighted code block and diff support
  • hand off terminal control to external programs like vim or less and reclaim it cleanly when they exit, or spawn processes and stream their output directly into your UI
  • a consistent look out of the box, customizable from a single theme object

to get started, run

see giggles.zzzzion.com for API documentation and live demos.

select

multi-select

markdown

text-input

viewport

codeblock

confirm

spinner

modal

paginator

autocomplete

command-palette

virtual-list

badge

panel

suspend the UI, hand off the terminal to an external program like vim or less, and resume cleanly when it exits

spawn a child process and stream its stdout/stderr output into your UI — with support for colored output via a pty

reactively track the terminal’s current dimensions (rows and columns), updating on resize

detect when the terminal window gains or loses focus

⚡ **What’s your take?**
Share your thoughts in the comments below!

#️⃣ **#zionoffgiggles #batteriesincluded #react #framework #building #rich #terminal #apps**

🕒 **Posted on**: 1772506323

🌟 **Want more?** Click here for more info! 🌟

By

Leave a Reply

Your email address will not be published. Required fields are marked *