Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Is Tauri and Dioxus similar projects, or those are made for different purposes?


AFAIK, Tauri is an electron replacement: a portable web view container where you can use any web tech to build an app. So you can build with JS/TS or any language that compiles to WASM. You can use the Rust native host but you don't have to.

Dioxus is a full UI kit for Rust. They stick as close as possible to React and even have CSS and Html syntax. But, it's not a web environment.


a quick read shows it tries to be 'flutter but in rust'


Neither Tauri nor Dioxus is trying to be flutter. The only similarity is that those projects exists in GUI space.

Tauri is an electron alternative. It handles windows creation, rendering of web pages as well as IPC between frontend and backend.

Dioxus is a frontend framework similar to Next.js and other react-based frameworks.

Flutter uses an entirely different approach to GUI.


The linked article literally states: Our goal is to build a "Flutter but better."


I never know how to position Dioxus, so would be happy to have some 3rd party insight.

When I say we use a webview, people immediately jump to Tauri. But we're very architecturally different than Tauri. No WASM on native, just a regular old executable.

When I compare us to Flutter, people immediately think of Flutter's negatives (poor web support). We have excellent web support (DOM is 1st class).

When I compare us to React Native, people immediately think the web is 2nd-class and then wonder why we don't implement NSScrollView and all that.

We are shooting for something like Flutter (web, desktop, mobile, embedded) but where the web is the defining feature.

As someone outside Dioxus, how do you think I should describe it?


> We have excellent web support (DOM is 1st class)

ah I missed that... I read something about Flutter and WASM and kind of assumed it was rendering to canvas

that's very nice


Edit: apparently the documentation indicating this was inaccurate -------- Original comment:

Dioxus appears to currently use Tauri for the desktop renderer (https://dioxuslabs.com/learn/0.6/guides/desktop/) so it seems like it's a cross-platform framework that uses tauri on the desktop.

However it seems like they to switch to their own html renderer for desktop at some point.


We don’t necessarily use Tauri… Tauri has a library called wry that’s basically a more maintained fork of the Rust web-view library.

https://github.com/Boscop/web-view

We are great friends with Tauri but I think people misunderstand our architecture and philosophy just because we use one of their maintained libraries.

We’ve been working on a native HTML/CSS library for a while called blitz which is reaching stability soon.

https://github.com/DioxusLabs/blitz


I'm guessing some of that misunderstanding comes from the fact that it states "Dioxus desktop is built off Tauri" here: https://dioxuslabs.com/learn/0.6/guides/desktop/


Oh, my bad. That language has never been accurate and I'm not 100% sure why it's phrased that way. Just pushed an update.


I'm just going based off of the page I linked (which appears to be the documentation for version 0.6 which was just released) which says:

> Dioxus desktop is built off Tauri. Right now there are limited Dioxus abstractions over the menubar, event handling, etc. In some places you may need to leverage Tauri directly – through Wry and Tao.

Maybe that paragraph is out of date though?

From your comment it seems like wry is not (currently?) based on Tauri so it doesn't seem like it would make sense to "leverage Tauri directly – through Wry"; was wry previously based on Tauri and is that part left over from before that change? Or did the person who wrote the documentation misunderstand how it works?


Oh, my bad. That language has never been accurate and I'm not 100% sure why it's phrased that way. Just pushed an update.


Different purposes- at least that's how it started / feels like it currently is.

A similar comparison would be Electron and React / React Native.

Tauri is a way to package a web app (e.g. could be react or svelte written in typescript) in a window and interface with rust code.

Dioxus is a way to write web apps (and other applications) in pure rust.


"Pure rust" is not quite accurate given the rsx! macro DSL stuff


sure it is. the macro is written in rust and used in rust and compiled using the rust compiler


the tooling might be in Rust, but now I have to write some new DSL that isn't Rust


The DSL is basically just Rust structs with optional fields. We essentially use the same struct parser rust uses but with some small tweaks.

You want to use a macro for this so you can do hot-reloading - doing it with native Rust is currently impractical for rapid dev.


how pure though if it's using react.


it isn't. it's "like react"




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: