Show HN: Rust GUI Library via Flutter
41–50 of 108 posts
Re: Show HN: Rust GUI Library via Flutter
#42Cool, but the point of having stuff in Rust is to ideally have everything in Rust, or you're by definition not getting all the safety benefits of Rust.
Not at all, pretty much all popular languages (except C/C++) are as safe as (safe) rust. The only safety rust brings to the table is memory safety, which most languages achieve with a runtime and a garbage collector, which have a performance tradeoff.
Re: Show HN: Rust GUI Library via Flutter
#43I have been using this to build an app[0] for the last couple of years and I want to say that it has been a pleasure to use, there are some wrinkles but overall I have been very happy with the experience. Upgrading from v1 to v2 was not too difficult and v2 is a significant upgrade with lots of useful features, massively improved codegen experience and support for tokio async were the big gamechangers for me. Writing…
Yeah I really like Flutter/Dart. I had less an issue with React itself than I did the whole HTML/CSS/Javascript ecosystem and tooling. Flutter is a breath of fresh air in that it is a purpose built ecosystem for UIs. You load the SDK and are ready to go with features like hot reload out of the box. No need for gamut of tools and to figure out how they all work together. Also, no need for HTML + CSS! I think the only reason it isn't more popular is because we have such a huge # of frontend devs already trained on HTML/CSS/JS, as Flutter is a lot simpler out of the gate, and much easier for traditional GUI paradigm people IMO.
Re: Show HN: Rust GUI Library via Flutter
#44I have been using this to build an app[0] for the last couple of years and I want to say that it has been a pleasure to use, there are some wrinkles but overall I have been very happy with the experience. Upgrading from v1 to v2 was not too difficult and v2 is a significant upgrade with lots of useful features, massively improved codegen experience and support for tokio async were the big gamechangers for me. Writing…
> I know Flutter/Dart doesn't get much love here on HN but in my opinion I think it's much easier to reason about than a system like React which I think is the wrong level of abstraction compared to Flutter's render the entire widget tree approach. Could you expand on this a bit? My impression was that Flutter and React had relatively similar approaches to components, but I haven't had much experience with Flutter ye…
Flutter = a UI framework for mobile/desktop/web (Flutter + Dart)
On top of the purpose built nature, nearly everything is a Widget, even layout/styling making it pretty easy to grok very quickly.
Re: Show HN: Rust GUI Library via Flutter
#45Re: Show HN: Rust GUI Library via Flutter
#46Cool, but the point of having stuff in Rust is to ideally have everything in Rust, or you're by definition not getting all the safety benefits of Rust.
Not at all, pretty much all popular languages (except C/C++) are as safe as (safe) rust. The only safety rust brings to the table is memory safety, which most languages achieve with a runtime and a garbage collector, which have a performance tradeoff.
- no undefined behavior
- many classes of concurrency bugs prevented by the type system
- standard library and much of the ecosystem makes invalid states unrepresentable. E.g. a String is always valid UTF8
Those are things that are true to varying degrees for other languages. Dart does pretty well imho. But for example Java and C# offer memory safety but have very unsafe concurrency
Re: Show HN: Rust GUI Library via Flutter
#47Earlier quoted context omitted.
> I know Flutter/Dart doesn't get much love here on HN but in my opinion I think it's much easier to reason about than a system like React which I think is the wrong level of abstraction compared to Flutter's render the entire widget tree approach. Could you expand on this a bit? My impression was that Flutter and React had relatively similar approaches to components, but I haven't had much experience with Flutter ye…
At a basic level Flutter renders the entire widget tree and caches components that don't need to re-render rather than applying a diff of changes to the DOM. But it's really the Flutter/Dart API and widgets that make it much easier to work with, if I need to load some data asynchronously I use a `FutureBuilder`, if I need a stream of events I can use `StreamBuilder` etc. Compared to Reacts state, hooks, memo, effects…
But I can imagine that the API can be easier. I think React handles state fairly well, but as soon as that state needs to interact with things outside the React world (http requests, continuously updating data, etc) then the current abstractions don't quite feel right.
Re: Show HN: Rust GUI Library via Flutter
#48Re: Show HN: Rust GUI Library via Flutter
#49I use Flutter for my desktop UI and Rust for my backend. However, I chose to separate the two using gRPC instead of the bridge. This allows me to be agnostic of language on both sides and I suspect gives me a cleaner interface for mocking the backend from my frontend. It also makes it easy to place the UI and backend on different machines giving a true client/server architecture. The con is likely that the interface…
Re: Show HN: Rust GUI Library via Flutter
#50Earlier quoted context omitted.
> I know Flutter/Dart doesn't get much love here on HN but in my opinion I think it's much easier to reason about than a system like React which I think is the wrong level of abstraction compared to Flutter's render the entire widget tree approach. Could you expand on this a bit? My impression was that Flutter and React had relatively similar approaches to components, but I haven't had much experience with Flutter ye…
React = one small piece of a very large required ecosystem (HTML + CSS + Javascript + NPM + React + Vite + ???) Flutter = a UI framework for mobile/desktop/web (Flutter + Dart) On top of the purpose built nature, nearly everything is a Widget, even layout/styling making it pretty easy to grok very quickly.