Show HN: A backend agnostic Ruby framework for building reactive desktop apps
Published on: 2025-07-21 09:01:11
Hokusai
A Ruby library for authoring GUI applications
Getting started
In your Gemfile
gem "hokusai-zero" , "0.1.7"
In order to run an application, you will need to install a backend
Raylib
Install raylib >= 5.0
Write your app
Run app with RAYLIB_PATH=/libpath/for/libraylib.(so|dylib) ruby .rb
SDL2
Install the following deps libsdl libscdl-gfx libsdl-ttf libsdl-image
Write your app
Run app with SDL_PATH=/libpath/for/libsdl.(so|dylib) ruby .rb
Example counter application
require "hokusai" require "hokusai/backends/raylib" class Counter < Hokusai :: Block template <<-EOF [ template ] vblock hblock label { :content = "count" size = "130" :color = "count_color" } hblock vblock label { content = "Add" @click = "increment" } vblock label { content = "Subtract" @click = "decrement" } EOF uses ( vblock : Hokusai :: Blocks :: Vblock , hblock : Hokusai :: Blocks :: Hblock , label : Hokusai :: Blocks :: Label , ) attr_accessor :count def increment ( event ) self
... Read full article.