Rails does this perfectly with Turbo and Stimulus, Turbo does HTML-over-the-wire via SSR-first, server responds with small updates/appends of HTML as need etc, and then you lightly use stimulus JS controllers for the small stuff where HTML/forms don't make sense. https://hotwired.dev/
While it's definitely possible to build similar website with Turbo and Stimulus it would absolute NOT be the same thing and the mechanics of it would be radically different. I would argue using SSR at all times (and, consequently, workarounds like Hotwire, which make it look like it's not SSR) is the same kind of sin as using React for SPAs for personal blogs (i.e. things, SPAs don't belong to).
Qite.js – Frontend framework for people who hate React and love HTML
141–150 of 168 posts
Re: Qite.js – Frontend framework for people who hate React and love HTML
#142I'm starting to wonder whether reactivity (not React specifically) was the originally sin that led to modern UI complexity. UI elements automatically reacting to data changes (as oppposed to components updating themselves by listening to events) was supposed to make things easier. But in reality, it introduced state as something distinct from both the UI and the data source (usually an API or a local cache). That int…
I genuinely don't understand why this model is the norm. As a game developer working in my own engine, UI is unbelievably straight-forward: the game has state. The master Render() function draws all of the graphics according to the current state, called at framerate times per second. Nothing in Render() can change the state of the program. The program can be run headlessly with Render() pre-processed out completely.…
To an extent this is how react works internally. There is a function which takes state and produces UI. In order not to have to re-render the whole UI if only a small part of the state changes, there is a diffing algorithm and "virtual dom" that is diffed against. Maybe it doesn't work exactly like that anymore but that's the gist of it.
Re: Qite.js – Frontend framework for people who hate React and love HTML
#143[flagged]
Re: Qite.js – Frontend framework for people who hate React and love HTML
#144The "isPresent()" in the example gives me alot of ick. It's confusing why thats not actual javascript.
total: (c,v) => v > 1000
See the docs: https://qitejs.qount25.dev/States/Field-Matchers.htmlRe: Qite.js – Frontend framework for people who hate React and love HTML
#145I thought I hated React until I saw the samples on this page...
Any time I see code in quotes I get the heebie jeebies. Code in quotes can't even be syntax checked until run time.
Re: Qite.js – Frontend framework for people who hate React and love HTML
#146I'm starting to wonder whether reactivity (not React specifically) was the originally sin that led to modern UI complexity. UI elements automatically reacting to data changes (as oppposed to components updating themselves by listening to events) was supposed to make things easier. But in reality, it introduced state as something distinct from both the UI and the data source (usually an API or a local cache). That int…
I still believe immediate rendering is the only way for easy-to-reason-about UI building. And I believe this is why early React took off - a set of simple functions that take state and output page layout. Too bad DOM architecture is not compatible with direct immediate rendering. Shadow DOM or tree diffing shenanigans under the hood are needed.
Meanwhile, those of us that were building web apps with JQuery and other tools prior to React know just how painful "web development without reactivity" actually was.
Re: Qite.js – Frontend framework for people who hate React and love HTML
#147Re: Qite.js – Frontend framework for people who hate React and love HTML
#148Re: Qite.js – Frontend framework for people who hate React and love HTML
#149The fields/flags state model is a nice idea, having structured values separate from boolean state is something I haven't seen in other frameworks. How does this compare to Alpine.js or htmx in practice? They're in a similar space (no build, SSR-first) but I'm curious what made you go with a new framework rather than building on top of those?
You can build similar things with Alpine/htmx, but once things grow, you end up reinventing structure. Qite just bakes that in from the start.
Re: Qite.js – Frontend framework for people who hate React and love HTML
#150I'm starting to wonder whether reactivity (not React specifically) was the originally sin that led to modern UI complexity. UI elements automatically reacting to data changes (as oppposed to components updating themselves by listening to events) was supposed to make things easier. But in reality, it introduced state as something distinct from both the UI and the data source (usually an API or a local cache). That int…
Absolutely. Look at facebook today. Back in 2010, everything had just the right amount of interactivity. Because, separation of concerns existed at the language level - HTML for structure and CSS for presentation, JS for everything else. Then some bunch of geniuses decided it would be awesome to put everything together in the name of components. Today, you open facebook, the creators of React - normal drop-down with…
As a previously big React dev I agree 100%. If anyone feels this way please spend some time on doing Sveltekit project (e.g. rewrite a personal React project).
It's a breath of fresh air.