Comment by bsmith89

6 hours ago

There's a great Signals and Threads (Jane Street's Podcast) episode about this work: https://signalsandthreads.com/building-a-ui-framework/

A framing from that podcast that helped me better understand the role of Bonsai is that it's really a framework for building incremental distributed state machines.

  • This framing is also in the post. From the readme:

    > Bonsai itself -- this library -- is actually more generic than the above makes it sound. It allows you to build general-purpose incremental, composable state machines. Bonsai_web builds on top of that core library, specializing it for interactive browser-based UIs, but we also have Bonsai_term for building interactive terminal-based UIs.

  • The docs are a bit sparing but if you read the source its pretty cool to see how they did this.