logoalt Hacker News

jpc007/31/20251 replyview on HN

> I want to (1) build blindingly fast, low-latency, super performant UX for users, … (2) maintain developer velocity, (3) have access to nice UX primitives and widgets … (4) have it look nice and modern.

Find me when you find this, because I actually think it is impossible.

I think there is fundamentally too much inherent complexity to abstract away to keep 2 and not sacrifice 1. Specifically for something properly cross platform.

If you are only targeting MacOS or windows then I think it’s absolutely possible but then you are using the wrong language, nothing against rust at all on that, the platform defaults are just swift / C# for those use cases.

And I’m not sure but unless you are just using a gtk/Qt style framework you would absolutely run into a11y problems that you would need to build around yourself.

Sounds like you probably want egui though… if your primary UI is a big canvas that needs to be hardware accelerated and interaction is just to assist that use case egui is probably a good bet for you. But you wouldn’t be hiring web devs to do that.


Replies

cosmic_cheese07/31/2025

I believe it’s possible, but it’s going to take a little bit of outside of the box thinking in that it’d be most practical if the UI toolkit isn’t bound strictly to a single paradigm.

Both imperative and declarative UIs have serious problems. Imperative toolkits can get hairy with their boilerplate and can make staying in sync with data state a real challenge, while declarative toolkits have a strong tendency towards rigidity that makes for awkward DX and ugly code in all but the simplest todo app kind of examples and don’t lend themselves to fine grained control.

I think there’s a happy medium to be found between the two in a well-designed hybrid. This hypothetical framework would allow full declarative in situations where that’s highly suitable, but would also allow the dev to do widget configuration in a more traditional imperative style or if necessary fall back to full imperative. Support for reactivity on both sides of the coin would be robust so staying in lockstep with data is simplified.

This would bring down boilerplate substantially since the broader layout of most screens could be done declaratively, but it wouldn’t come at the cost of more advanced functionality, flexibility, and developer control on the individual widget level.

I’d like to dig further into these ideas at some point if I get time.

show 1 reply