logoalt Hacker News

Electron vs. Tauri

76 pointsby birdcultureyesterday at 8:06 PM37 commentsview on HN

Comments

Arrowmastertoday at 2:57 AM

The author has obviously never tried Tauri on Linux. I've never seen one of their AppImages work correctly. Every project uses the upstream GitHub action to build binaries and it compiles dynamically linked binaries limited to the glibc from the Ubuntu 22 or 24 VM used. Xdg-open is often broken too from broken environment variables in the AppImages, so you can open a link in the default web browser. The entire build process needs reworked.

show 8 replies
lone-cloudtoday at 8:32 AM

- "Electron comes with a few rather significant drawbacks" Not going to mention them at all though? - what possible reason could one have to use Next with Electron? Not everything needs to be in Next and there's no reason for SSR + Node.js API server (primary advantages of Next vs React) when the client and server are on the same machine. The author's solution is to wrap this with another dubious framework (Nextron looks abandoned and hasn't been updated for over 10 months btw) to force them to somehow work together. Like why? - the idea behind Tauri to leverage the user's system's webview may sound like free real estate, but as many Cordova devs have previously found out, it's incredibly risky when you have no control of your own runtime. Desktop webviews are not a uniform layer. Ex. Webrtc is not supported on Linux webviews.

show 1 reply
dfabulichyesterday at 10:40 PM

> Lack of support for .appx and .msix bundles on Windows

https://github.com/tauri-apps/tauri/issues/4818

Whoa, I had no idea about that. Tauri is way less fully baked than I realized.

The bug goes on to explain that Tauri apps can't have Windows "package identity", which means that there's a bunch of Windows APIs you simply can't use in Tauri, including the notifications API.

Without package identity, IMO, Tauri isn't ready for primetime on Windows.

show 1 reply
sundarurfriendyesterday at 11:09 PM

> As you’d expect, this makes Tauri apps far more lightweight.

Note that lightweight compared to Electron does not mean it's actually lightweight. In my experience, Tauri apps are still pretty heavy and a constant drain on system resources; maybe they're 2x better (faster/lighter) compared to an Electron equivalent, but they're still at least 10x worse compared to native apps.

With a Tauri-based app (just like with Electron), I have to constantly remember to close the app at the soonest possible point in time, or I can tangibly feel the sluggishness it creates in the system performance. So if there's a native choice and a Tauri-written choice, I'd heavily prefer the native choice nowadays, even at the cost of some features.

show 2 replies
WhyNotHugotoday at 3:51 AM

I tried using Tauri a few weeks back, and the build system is an absolute nightmare.

I gave up after a few hours. The last issue I encountered was it trying to link udev and libinput. libinput is a library for writing compositors, and their website literally state "libinput is not used directly by applications". I've no idea why Tauri was trying to link this (and some rough ideas of why it wasn't working due to the absence of udev on that host), but at this point, I didn't care any more.

haideralshammatoday at 5:55 AM

I am building an open source desktop app in Tauri [1]. One of the issues I encountered was having to duplicate and sync types between the TypeScript frontend and Rust. On the other hand, Rust proved to be a great language with a sizeable ecosystem for building application backends.

[1]: https://github.com/haideralsh/prompt-lab

show 1 reply
iamsaitamtoday at 8:24 AM

"Compatibility issues across system webviews are exceedingly rare, especially for the major operating systems."

When it comes to CSS, there will be the same vendor issues that you have on websites. It's not a magic bullet.

ifh-hntoday at 9:13 AM

Would love to see these in comparison to desktop flutter.

pjmlptoday at 7:45 AM

What about neither?

If it must be Web, run the application headless and launch the system browser.

But really if 50 year olds can jungle between native and Web, so do you.

kristianptoday at 1:20 AM

How does Wails compare here? I'm guessing it's less mature than Tauri.

show 1 reply
mootodaytoday at 4:51 AM

My personal favorite to keep an eye on is https://www.gpui.rs/.

It's what Zed(.dev) is based on. While not quite ready for prime time from what I understand, if Zed is the reference implementation, I'm sold!

show 2 replies
testdelacc1today at 7:43 AM

> Tauri doesn’t seem to be able to create Mac universal binaries from their arm64 and x64 subcomponents.

I think this problem will be “solved” on its own. According to the October Steam hardware survey, about 15% of macs are still on Intel, with the number dropping each month. In a year it’ll be less than 10%. The software side isn’t looking good either - Intel Macs have received their last OS update this year. In 2028 Apple will classify Intel Macs as “vintage”, ending most service and parts support.

I’m not making a judgement here on Apple’s decisions. But Tauri is unlikely to spend their time optimising for a small fraction (Intel) of a small fraction (mac users), which is also reducing over time. Their time is probably better spent getting Windows support up to scratch because Windows isn’t going anywhere.

auggierosetoday at 7:40 AM

Of course a lot of apps will not be able to live with the restrictions, but if you can write your app as a webapp (PWA), you should do that instead of using Electron or Tauri. I do it because I find either build system atrocious, and with webapps I can just use esbuild. Using Chrome for example, people can install webapps as desktop apps on any operating system, if they like, and the footprint is minimal.

anon115today at 2:24 AM

i had a better time vibe coding with gpt 4 with WAILS> vs any of these Electron> Tauri

show 2 replies
aabhayyesterday at 10:33 PM

If they didn’t have the nodejs dependency then the Tauri bundle could be as small as 20mb.

Another pro not mentioned is that native integrations (i.e. obj-c on macos) are much easier to do since rust has great ffi integration with other native libraries.

The biggest pro to electron is that it has extensive plugins that are often widely used in production by large companies. But Tauri is definitely winning and any new project should use Tauri no matter what essentially.