I didn't submit this, but I'm the lead dev for Blitz. AMA.<p>One thing to note is it's not quite ready yet:<p>- The text input and focus system are pretty basic<p>- We don't support scrolling (other than the root viewport)<p>- Complex CSS selectors like nth-child and :has aren't working correctly yet.<p>- Event handling integration with Dioxus (the React-like framework that sits on top of Blitz) isn't robust or fleshed out yet (only clicks work, there is no preventDefault)<p>- The currently networking is super-dumb and does synchronous requests on the main thread. We need proper async and/or multithreaded networking.<p>- We have put very little work into performance - we're currently recomputing style/layout/paint every frame.<p>- Relatedly: We have few dumb memory leaks where nodes are not cleaned up. We know where these are, we just haven't fixed them yet.<p>- Less critical, but things like shadows, web fonts, calc, float layout, and form controls other than text input are missing (see README for more).<p>All of these are basically a case of "building a webview is a big task, and we haven't gotten around to that yet". We're hoping to have something a bit more complete in 2-3 months time.<p>There are some more screenshots here:<p><a href="https://github.com/DioxusLabs/blitz/issues/23">https://github.com/DioxusLabs/blitz/issues/23</a>
This project looks very useful at a glance.<p>Create native applications that use the widely popular HTML/CSS paradigm for layout, but leave out much of the heavyweight stuff that a full JS/DOM/browser API implies. This looks like it can enable very large improvements over packaging browser engines like electron etc. do.<p>Funnily enough, I just recently listened to Casey Muratori on Richard Feldman‘s podcast, where they where extremely critical of CSS.<p>Some of the stories they told, like having to prerender and dynamically measure web pages in order to achieve some very simple layout relationships hit right at home.<p>Writing CSS feels, as Muratori said, more like presenting a case in the court of law, instead of building upon simple primitives.<p>Now there’s of course a very widespread need or want that is met by this project. Not just in terms of familiarity but also compatibility and the fact that „happy path CSS“ is incredibly productive.<p>But maybe there’s an opportunity to provide a simpler, general layer that a user of this can drop down to.<p>Perhaps the authors can find inspiration by looking at CSS houdini, which tries to make CSS extensible via a JS API. Or maybe that’s what they mean by „Custom Widgets“?
I built an open source project like this some years ago (holy carp! 20 years ago) called Flying Saucer. It was a pure Java HTML + CSS2 renderer.
I imagined people would use it to render rich text UIs in games, but the killer use ended up being server side PDF generation. It was far easier to generate HTML and render to a PDF than to use the various PDF report generation APIs available at the time.<p>Blitz looks cool. I'm excited to see more GUI libs in Rust.<p><a href="https://en.wikipedia.org/wiki/Flying_Saucer_(library)" rel="nofollow">https://en.wikipedia.org/wiki/Flying_Saucer_(library)</a><p>PS: amazingly it is still being updated!
<a href="https://github.com/flyingsaucerproject/flyingsaucer/releases/tag/v9.9.0">https://github.com/flyingsaucerproject/flyingsaucer/releases...</a>
> It is effectively a lightweight webview except that the JavaScript engine is replaced with a native Rust API<p>Woah, this looks promising. Basically Tauri without JS in the loop? Music to my ears.
Interesting. Just today I was looking for wkhtmltopdf replacement after a horrible experience with puppeteer and trying to run chromium headless (do NOT try to run it with jemalloc in LD_PRELOAD). I did solve the problem, but I preferred the simplicity of a renderer.
Not a comment on Blitz itself, but had never heard of Dioxus before. Is there some unwritten rule about compiles-to-wasm type frameworks where they never actually show a demo or have their own site self-hosted in the framework? Seen this like 5 or 6 times now. I see some wasm file loaded on the Dioxus home page, but it's not clear where it's being used if at all
That's really cool! Would love to use it in my c++ projects. One thought that came to my mind: How is the performance? Could you render a relatively complex page at high frames per seconds? I usually use ImGUI which is excellent to display real-time data without even thinking about performance issues. Compared to Chromium's web rendering which burns my CPU already at 10FPS simple DOM text updates, this could be a game changer.
Looks really interesting and lots of strongly favourable responses in this thread. For those in the know: what’s something like this used for? Where does it fit in to the landscape? Is it a case of filling a specific need in the Rust front-end ecosystem, or something more language and framework agnostic? I’ve very little front end experience - the repo readme went over my head.
This is impressive work, I greatly appreciate the "lightweight" aim but would it not make sense to use Servo, perhaps with build feature flags to reduce size?