When I first discovered RxJS, I was hooked. The idea that everything could be a stream was mind-blowing. Events, state, async logic — all handled in a clean, functional way. But as soon as I started using it for real UI work, the excitement wore off.
I found myself writing endless boilerplate just to update text on the screen. I had to juggle Subjects, Behaviors, and operators for what felt like the most trivial tasks. And whenever I came back to my own code a week later, I had to mentally re-map how everything fit together.
RxJS was powerful, but it wasn’t fun.
The “aha” moment
One day, I asked myself: What if the DOM itself was reactive? Instead of bolting RxJS streams onto the UI with manual subscriptions, what if the UI could natively understand Observables?
That thought snowballed. I sketched ideas, built small experiments, and eventually arrived at what would become Rimmel.js — a stream-oriented UI library designed to solve the pain points I kept running into with RxJS.
From friction to flow
Take something simple like counting button clicks. With vanilla RxJS, you need setup code, subscriptions, and cleanup. With Rimmel.js, it looks like this:
import { BehaviorSubject, scan } from "rxjs";
import { rml } from "rimmel";
const count = new BehaviorSubject(0).pipe(
scan(n => n+1)
);
document.body.innerHTML = rml`
<div>Clicks: <span>${count}</span></div>
<button onclick="${count}">Click me</button>
`;
The stream and the DOM just fit together. No glue code, no manual subscription management — and when the stream emits, the UI updates automatically.
Why I built it
I didn’t set out to make a “framework.” I just wanted RxJS to feel more natural for UI development. But over time, I realised Rimmel.js could help others who had the same love–hate relationship with RxJS that I did.
- If you’ve ever fought with Subjects just to hold state
- If you’ve ever written way too much code to bind an Observable to the DOM
- If you’ve ever wanted RxJS power but without its steep learning curve for UI tasks
…then Rimmel.js might click with you the way it clicked with me.
The bigger picture
Rimmel.js doesn’t replace RxJS. It builds on top of it. You still get all the expressive operators and the reactive model you know, but now you can write UI code that feels like it belongs in that world instead of constantly fighting it.
For me, that shift turned RxJS from a headache into harmony.
👉 I’d love for you to check it out on GitHub, play with it, and share your feedback. Maybe it’ll save you from the same RxJS headaches I used to have.
Top comments (1)
The neateast way to use RXJS I've ever seen, indeed! Great work!