I build a Mastodon client with Dioxus last year [1] and it was in general a good experience, but it was also clear that lots of things were still missing (I mean, it was also at version 0.2 when I started working on it).
With these 0.5 changes the Dioxus authors remove almost all the complexities that I ran into when working on Ebou. I haven't played around with it yet, but the removal of lifetimes and constant cloning will make it a much more pleasant experience. I'm looking forward to trying it out, congratulations to the team for such an awesome release!
How did you choose Dioxus?
There are about a dozen Rust frameworks [1] that are trying to do the "native, reactive UI" you can deploy on desktop, web/wasm, mobile, etc. I'm worried about betting on the wrong horse and being stuck maintaining abandonware or being faced with a painful and pointless migration.
In a similar evolutionary race, there were dozens of Rust HTTP server frameworks. Now Axum, Actix, and Rocket appear to have the lead. I'm worried I made the wrong choice as the community momentum appears to be shifting to Axum.
Is there any indication Dioxus will win? It looks to have a large community, venture backing [2] (a good sign!), and more momentum than some of the others. I'd like to use one of these frameworks now, but I worry it's too early to place a bet. Are there any good indicators that now is a good time to start using it?
Are Leptos and Yew the other top contenders? These are the two names I hear the most, apart from Dioxus. What would make them a better (or worse) choice?
My company is heavily invested in Rust, Actix, and Bevy. We're looking at pairing Bevy with Dioxus or a similar framework to deliver native desktop and mobile clients in the future. I just want to make the right choice.
Also, stupid question: is Dioxus named after the Pokemon [3]? The logo makes me think there's something to that, but there are no Pokemon references in the codebase.
[1] https://github.com/flosse/rust-web-framework-comparison
[2] https://www.ycombinator.com/companies/dioxus-labs
[3] https://m.bulbapedia.bulbagarden.net/wiki/Deoxys_(Pok%C3%A9m...
Creator here, so I'm biased...
Yew has had about 10 commits in the past 6 months and the original creator has since moved on.
Leptos is a good solution for web-app type stuff, but IMO there's a big usability gap. I'll let the community be the judge there, but I wrote up some differences here: https://github.com/dioxusLabs/dioxus/?tab=readme-ov-file#dio... Leptos was fortunate enough to receive a lot of attention from youtubers on its launch.
The most important thing here: we raised venture money for Dioxus. We have many years of runway, are pretty lean, and exclusively focused on pouring resources into making the best GUI library for Rust (and potentially branching out to Python/JS). Getting into YC isn't easy, raising money isn't easy, and there's currently no other Rust projects with similar goals, talent, and financial backing. Biased of course.
Oh, and we're committed to the bevy integration. bevy_dioxus is already updated for 0.5 and we share corporate sponsors with the bevy folks.
Final point, legally, no we're not inspired by any pokemon with a similar sounding name. Even though that pokemon is awesome.
Important, but in a _bad_ way? What will the VC expect out of Dioxus? How will you make money?
Yeah, it's becoming more common in my group of SWEs to specifically opt to NOT use VC backed software. Everyone has stories about companies closing shop and projects failing to continue onward.
Why would Dioxus be any different? If VC's cared about tearing down walled gardens of Google and Apple, why not explicitly donate the money instead? Why have strings attached at all?
so, what they use instead? Bugged, dead OSS dropped by creators?..
No, normal OSS whose existence isn't tied to VC mostly. It's not like a hard/fast rule, just a heuristic.
There are very few good quality, stable, active OSS projects which is not fed by VC/corps money. In this case (UI for rust) there is no much choice.
Funding by VC and funding by corps sponsors are 2 very different things. Check how linux desktop projects such as Gnome & KDE kept the lights on for >20 years without VC funding.
Ok, if you find corp which will give you funding for your project without any expectations, then it is a win. But I am not sure how often this happens.
There are expectations of course, but the ones from a corp will be different from a VC. Typically the corp will expect you to build something they need and can use, a VC will only want financial return on investment.
"There are more things in heaven and Earth, Horatio, / Than are dreamt of in your philosophy."
We have grants and corporate sponsors to keep the project alive even if the VC money runs out. This was all a side project for me at first, so I went down the "donation" route in the beginning.
Donations are great but they're not how the system works, unfortunately. Dioxus could never compete with the two most valuable companies on earth if it wasn't a self-sustaining business. VC just lets me scale the team from 2 people to 10(?) and have some cash to iterate. We were "profitable" even before taking venture money.
Now we're able to take on more moonshot-type projects like the blitz renderer, a deploy platform, UI fuzz tooling, and more. We're using our seed round exclusively to make dioxus as awesome as possible, so even if it doesn't work out at a venture level, there's still a really cool, polished, end-to-end app framework that you can build and ship with in Rust.
That's fair and you're welcome to chart your own path, but I like what Tauri does with their governance model:
https://dracc.commonsconservancy.org/0035/
https://tauri.app/about/governance
Just for me personally, I don't see the financialization of open source software as an intrinsic good thing and I reflect my technology choices to support this when applicable.
We'll probably explore that in the future but right now our team is literally just 2.5 fulltime engineers.
Tauri is seeking monetization via CrabNebula, but I can see how the governance structure would secure more confidence in the OSS side.
http://crabnebula.dev
For a GUI based project, I'd actually prefer they were VC and/or corporate backed with clear governance.
OSS backend libraries are easily forked, and someone is usually willing to hack on a database library, but GUIs tend to be boring to work on, and designers don't tend to have to the same gumption to work for free that developers do.
Venture doesn't necessarily mean bad. Long term the goal the goal is to dissolve the gates to Apple and Google's walled gardens, which I personally believe is a net good.
As much is the idealist in me wants to do that with no venture backing, the realist in me knows we need Dioxus to be self sustaining and providing legitimate value for people to switch. Google spends 76 million dollars a year on catering alone - there's no way you can compete with Android and Flutter without huge resources.
Apple and Google capture the value for their platforms via fees and lock-in. Our goal is to capture value by providing really good utilities for building and deploying apps. You can't move heaven and earth without a really big lever, and venture gives us more leverage.
If you don't mind me asking, what's the actual business model here? Are you going to charge for those utilities?
Yes, we're looking at something like a Vercel/Expo model, probably built on Fly, Cloudflare, or AWS, but designed to be self hosted.
We've got a decent amount of enterprise adoption and I think there's money to be made by selling something like a self-hosted Vercel. TBD on licensing - I'd want it to be open source but we wouldn't want people reselling our deploy platform.
We raised a seed to prove that people want to build with dioxus. If that hypotheses is validated, then we invest in the deploy model. If not, we have OSS grants and corporate sponsors that will keep the project alive for years even if the VC money runs out.
I'm not super interested in making money at the hobbyist tier - those developers are our evangelists. Enterprise self hosting is likely harder but I think we can provide a lot of value to teams building apps in large companies.
Cool stuff man, wishing you and the team all the best as a person who quite often uses Flutter for side projects but isn't a big fan of Dart. Any ETA on it being stable/1.0?
Stable/1.0 is always tough to call, and you can't predict the future of course, but it does seem obvious that enterprise value 1.0 software. It's more likely that we 1.0 different pieces of the stack (core, rsx!, html) so the ecosystem can build on top of stable primitives. We probably couldn't 1.0 the renderers themselves for a while.
It's probably another year of iteration until I feel like we're 100% stable, but my penchant for another rewrite is at an all time low.
Neat, thank you!
As a former Expo employee and someone who took a run at this space (moxie) before running out of steam, it’s really exciting to hear this is the approach you’re taking! I’ll be keeping an eye out :).
Speaking of Flutter, that and Electron seem to be the only really mature multi-platform build systems.
What is Dioxus's competitive proposition vs those two? The performance and memory efficiency+safety of Rust is one, any others?
I'd add React-Native / expo to your list.
Flutter is written in Dart but renders to a canvas on the web making it a very, very poor choice for web apps. Especially backend/fullstack apps. Plus you can't use tailwind or whatever flavor of css library there is today. Flutter just nailed the "get up and running" part which we've got as well: `cargo binstall dioxus-cli`, `dx new`, `dx bundle` is literally less than 30 seconds. Hopefully `dx deploy` coming soon.
Electron is... it's electron. A whole chromium instance, an IPC bridge between your frontend and the system, NodeJS, etc. If you compile for size, our desktop apps are 3mb. You can easily deploy them on an embedded/low end device. We're hoping to eat some market share in the embedded-ish land (not true embedded, but like industrial or POS).
Dioxus also has mobile and desktop compatible server functions which basically no other projects have. Expo has been kinda exploring this space. One of our examples is deploying your own LLM on your own infrastructure with a dioxus mobile app UI and it fits in a single file and builds in under a minute.
Flutter has an HTML renderer (https://docs.flutter.dev/platform-integration/web/renderers), but it's lower-performance than CanvasKit.
Thanks, wasn't aware of Expo, though it seems to only do mobile+web apps but not desktop apps?
> If you compile for size, our desktop apps are 3mb.
I'm aware of this from familiarity with Tauri, but hearing it again still amazes me. Very cool.
I have an app in mind I want to build, and really would like to have standalone versions on Android+iOS+Linux+Mac+Windows, plus a web app. But there's no way I can manage all that as a single developer. And the fact no development tool has really nailed this yet is telling how hard it is. Whoever really gets this right will save a ton of developer hours across the industry, and that's valuable. Good luck, hope you guys pull it off!
PS - one feature request: a local/offline-first mode that eases development of apps that work even with poor or no internet connection. Basically I want to build something like Obsidian that is multi-platform, and does all processing and data storage locally first, in an accessible format like SQLLite or flat files, then syncs with the cloud when available, all with as few developer resources as possible. A tool that enables that would be amazing.
there are several ways to monetize:
- consultancy
- "Pro" extensions on top of OSS core
Consultancy is unlikely to give VC a 100x return.
Enterprise extensions means the cursed land of open core and refusing to have features in the open source version, or a heavy SaaS push combined with a possible license change along the road, and these are the primary reasons to avoid VC-backed "open source for now".
yes, there are risks in exchange of VC money. You can branch your "Libre" project any time, and continue building on top of infra developed using VC funds and which you get for free.
But what are other choices?
I checked out the crate and am still a bit confused. If i may, is it a goal of bevy_dioxus to allow standard bevy gamedev but with the UI portion handled by dioxus?
Yes, a big feature bevy is lacking is a decent editor. There's been an ongoing push to get dioxus into bevy to accelerate the editor development. Bevy's ECS model is good for games but hasn't been cleanly mapped into the traditional GUI space yet. Dioxus is composable so you can integrate it at multiple levels. The bevy folks are using our virtualdom plus state management with their own renderer.
Silly question, but where can I see the updated bevy integration?
It looks like https://crates.io/crates/bevy_dioxus/ is still using dioxus 0.2 and bevy 0.7 - both of which are quite old. Does your official bevy integration have some other name?
Axum is certainly where it is at and where it has been for a while in terms of HTTP server frameworks. I'd say actix is in second place for sure, but it is wholly viable regardless. Rocket is no longer in the running as far as I'm concerned, and it hasn't been for quite some time.
Dioxus is certainly taking the head spot in front end. I still have more concern about the venture backing than I have confidence about it, but for better or for worse, it is certainly the best attempt at this so far. I enjoyed yew as a react-style framework, but its development is slow. Dioxus has made a lot of progress, and in my experience, it is currently the best experience that can be had.
It's hard to say if now is the correct time, but I'd be watching it closely if I were you. There's been major work to improve the framework with many of the interfaces changing. Now might be a good time because of the progress made here, but I wouldn't be surprised if there were more changes in store. Although I imagine that you're used to that from bevy anyway.
Not sure if you've already seen this, but back in November, Rocket 0.5 (stable) was released, and a 501(c)3 dedicated to Rocket was formed that now owns the Github org, etc. As a result, it's been getting much more regular updates, with the original maintainer still involved in development but no longer the only person with push access.
I'd certainly agree that it's no longer the de facto top leader, but as a batteries-included HTTP server, it works well (it's been chugging along powering my personal website for years now) and as far as I know still has quite a sizeable userbase.
[1] https://rocket.rs/news/2023-11-17-version-0.5/
I'd say leptos and dioxus are the bigger ones now i feel like many people moved from ywe to those 2
I'll second that. I was working on a GUI frontend for sshfs in Dioxus about 9 months ago. My impression was that it's a really, really good GUI framework... until you run into a wall because the developers aren't finished with some feature yet.
Sharing state across different contexts can also be a pain sometimes, but that's true of every GUI framework I've ever used, regardless of language or underlying technologies. Dioxus 0.5 looks like a big leap forward in this regard.
My blog uses Dioxus to render a sizable portion of its HTML. In that use case, its limits aren't pushed, and it does a wonderful job.