Live data from Hacker News

Tauri: An Electron alternative written in Rust

tauri.studio

381–390 of 438 posts

Re: Tauri: An Electron alternative written in Rust

#381
post #255

Earlier quoted context omitted.

> Electron gives the promise of total code re-use across platforms which is what makes web technologies more suitable for desktop apps. I am not sure what the point is of Electron: a shitty-resource hungry app that literally is a wrapped web-app. Instead of writing platform specific apps that leverage the power and capabilities of those platforms, we get a jack of all trades and master of none. Electron is a business…

Electron exists because there's a horde of developers whose only tool is a JavaScript hammer, so every problem looks like a nail. That's how you end up rewriting `dd` for Chrome[π]. π: https://www.balena.io/etcher/

The actual duplication is done in the Node.js runtime, not the V8 runtime inside of the Chromium GUI layer.

I do wish they had a command-line version that just ran node without Chromium, but there is a use-case to have a simple foolproof application like this; these days there are a lot of people who need to image drives like this and would be best not to mess with dd on their first time.

And dd doesn't exist for Windows so you've got to use some tool or another like this.

Re: Tauri: An Electron alternative written in Rust

#382

Earlier quoted context omitted.

I think we got there also by desperation of lacking good cross-platform GUI toolkits. The current state is, you either use something that looks like Windows 95 in all platforms, or web app. What the web made possible is to anyone to create a decent custom UI with little effort. I still remember how messed up was to create a custom component for Java Swing, which I believe is still one of the easiest to do. How would…

I'll take Win95 in a heartbeat; consistent, accessible, responsive and clear. Vastly superior to the majority of web interfaces.

Also totally inflexible, you better have the right-sized screen/resolution: too small and you can't see that "ok" button; too large and you'll have a ridiculously small and crammed winform to fill/see your information.

Re: Tauri: An Electron alternative written in Rust

#383
post #365

Earlier quoted context omitted.

Electron should be banned for the environments sake if the other reasons doesn't persuade, it's inefficient computation to energy ratio using Electron apps, when there is a lot of users like with VSCode or Slack it probably affects the global climate in a negative way

> it's inefficient computation to energy ratio Probably true. > affects the global climate in a negative way If electricity consumption of all computers in the world doubled because of Electron apps, the total annual electricity consumption would increase by 0.01%. So probably false.

In 2012 PCs (only PCs, not network appliances, not data centers, not phones...) were estimated at 1.5% of global electricity use, so you're off by a good margin. And that is deeefinitely not negligible, nor is the need (and eco impact) to buy newer computers because a 2016 MacBook Pro is unusable when your work requires 4/5 electron apps side by side.

Re: Tauri: An Electron alternative written in Rust

#384
post #279

Earlier quoted context omitted.

That's not my experience, at least. I haven't had any major issues I wasn't able to solve with either. Even if I were more comfortable with web tech when I first started experimenting with this stuff (some time around 2012-2015) I still found the end result much better.

If you don't go beyond standard interactions and look it's probably fine but let's say I want system chrome to look like the one in photoshop and some custom dropdowns for starters...

... it'd be doable ? E.g. look at telegram which is a Qt app and even more foreign-looking than Photoshop: https://images.app.goo.gl/JVNR4Jetmh7frvwo6 . Or allegorithmic substance, also made in Qt: https://images.app.goo.gl/CbJaGhRvSswymAjQ7

Re: Tauri: An Electron alternative written in Rust

#385
post #7

Downloaded the demo app for macOS; feels like an alien UI even though effort was clearly made to use system widgets. On the positive side, the app is only 4 MB and consumes 50 MB at runtime, so at least they've succeeded in that important aspect.

If I'm not mistaken, this is just because the CSS styling isn't that good, right? Take Slack (which uses Electron) as an example: it looks almost the same on Windows and Mac, but it looks good — because the styling (through CSS) is good.

Slack definitely does not look good when your definition of "looks good" is "integrated with the rest of the OS"

Re: Tauri: An Electron alternative written in Rust

#386

Earlier quoted context omitted.

It isn't your fault that you have to do this, it is that our industry hasn't created enough quality, easy to use, cross platform gui libraries for popular languages, such that the only viable place to turn is to use a whole web browser.

We've had about 60 years and multiple huge attempts at it, and IMHO HTML & CSS _are_ the easy to use cross-platform GUI platform. Nothing else stuck--flash, java swing, qt, etc. were all super capable and promising but failed to gain mass usage. HTML & CSS is the way. Nothing in existence has as much capability, developer usage and talent pool, accessibility and internationalization features, etc. A good GUI system i…

> were all super capable and promising but failed to gain mass usage

Depends where you look. Plenty of hardware devices use Qt as their UI. Modern Mercedes-Benz and Ford cars, LG TVs UI, stuff like the Remarkable tablet or th Telegram chat app... The nice thing being that you can test the UI on whatever OS you're running. Also, i18n on the web ? Come on. It's terrible when compared to Qt tooling

Re: Tauri: An Electron alternative written in Rust

#387

Question: Why do we need Electron alternatives? Why do we need to develop applications that need a bundled browser to run? Why can't we just use GTK/Qt?

Have you tried developing relatively complex UI with QT? You need to hire a team of engineers and spend man-years of effort to build custom UX that in the web / Electron can be replicated with an npm install fancy-library. Yes, I hate Electron, but the alternative is not QT; it's something like Sciter.JS with real Web API compatibility (or perhaps a stripped down WebKit2 which is much less resource-heavy).

I worked in a job where people developed very similar Qt and Electron apps, in both cases it was a one person effort and the development took about the same time.

Re: Tauri: An Electron alternative written in Rust

#389

I think the desktop seriously needs a production, RAM and developer friendly breakthrough that isn't Electron. Tauri may be it, but the desktop SO needs this moment, I don't want to see 50 years on and Electron is still being used.

I'm really hoping Flutter or Kotlin Desktop have a breakthrough here soon. Personally, I'm rooting for Flutter, but I'll take what I can get.

It would be fun that Dart finally takes over Javascript this way (Flutter is written in Dart, which was originally written to be the new Javascript)

Re: Tauri: An Electron alternative written in Rust

#390

Earlier quoted context omitted.

> I have never bought a prebuilt Windows PC, so this is pure speculation, but I am wildly guessing that the dominance of Chrome is because computers are now coming with Chrome preinstalled and configured as the default I'm not aware of any Windows machines shipping with Chrome pre-installed. But as soon as you use any website that's owned by Google you get spammed with install links for Chrome.

An entire generation is being raised on Chromebooks. I wish Boot2Gecko and Firefox OS weren’t a bit ahead of themselves and had better ugh marketing.

Entire generation where? Let's say I saw exatly 1 guy with a chromebook through my life, and likely chromebooks weren't even officially sold in my country. And still Chrome is the most popular browser here.
Post reply on HN