Hacker News new | past | comments | ask | show | jobs | submit login

> which is why now almost every single piece of software has installer that's at least 500 MB large.

I know pessimism about software is in fashion, but exaggerating the problem doesn't help. The actual size of the latest version of Electron (on Windows) is 181 MB uncompressed, 77 MB zip-compressed, and 51 MB 7z-compressed. Not great, but again, let's not make it look worse than it is.

Also, there is hope. Microsoft's WebView2 [1] means that Windows has a modern, shared, embeddable web rendering engine for the first time in several years. And Tauri [2] is making it easier for web developers to take advantage of WebView2 on Windows, and WebKit on Mac and Linux, to create lightweight native applications using web technologies.

[1]: https://docs.microsoft.com/en-us/microsoft-edge/webview2/

[2]: https://tauri.studio/en/




I have two Electron apps on my computer, one is 470MB and the other 511MB.


Which ones? I have two too (Obsidian and IRCCloud), each weighing in on 88M and 52M. So it does seem it's possible.


That doesn't mean it's elecrron taking up the space. Native apps are ofteb much larger than that.


At the moment, realistically using WebView2 requires shipping a WebView2 Runtime, either a fixed version or a bootstrapper. That's still over a hundred MB. I don't quite understand why that isn't being included with Edgeium, maybe it will be there in the future, but as of now, having Edge installed is no guarantee that any software trying to use WebView2 will work.

I've got too many scars from needing to ship shared Microsoft runtimes in the past to be entirely happy about this current situation.


Webview is not a replacement.

Webviews for GUIs is the worst of all worlds. You're packaging up two separate event based runtimes, chromium and node, and have no ability to interface with V8, meaning youre actually losing significant performance by having to serialize/deserislize data from node, to the browsers window, then deserislized on message in the browsers packaged JS engine.

It makes no sense to treat your desktop GUIs as closed sandboxes, what's the threat model?

Electron is not simply chromium, it has a bunch of optimizations, fixes, and prebundled functionality.


This entire thread is about which webview to use as an actual web view in an otherwise native application, not trying to use them as apps


Shipping WebView2 runtime "in-box" in Windows is supposed to start with Windows 10 21H2 and Windows 11. I believe soon after both release (Chromium) Edge will also start shipping it by default down to previous Windows 10 versions still in security support.


I've got a lot of scars from MS... but the bootstrapper is 1.7MB. It will then pull in WebView2.

WebView2 btw is awesome (I've spent a lot of time with it already, see my profile if you want to know why)


Well bashing Electron is popular, this is why even a blatantly incorrect comment is automatically the top one as long as they are denigrating Electron.


Just wanna give a shout out to tauri's mobile site; it has a "Learn More" button prominently on the first screen, ABOVE the standard "Get Started" button most projects use. I greatly appreciate the opportunity to understand what I'm starting before doing it.


Webviews can't access the V8 engine, have different implementations on every platform, and are worse in performance.

As a business would you save 120MB in filesize, or thousands of hours in development time?

Electron isn't even unique in this. Blender is over 200MB now. Photoshop and Autodesk products have been big for a long time.


I'm still getting my head around electron development, but only the main process in electron is really supposed to access the V8 engine right (if you turn sandboxing on anyways). With sandboxing on, you're still doing IPC from your render context to some backend, where for webview would be whatever framework is using the webview right?

Is the V8 performance benefit really that high compared to something like C# just calling system calls?


I’d assume it’s more about the tooling and libraries for JS. If I want to build an HTML based UI, I have thousands of JavaScript libraries alongside thousands of developers who know how to use them. If I want to build HTML that calls into C# I’ll need to do a lot more work myself.


Blender includes art assets like HDR cubemaps.


And so so so much functionality. Video editor, modeler, several renderers, image editor, python text editor, sculpt software, importer, video audio mixer, compositor, graph editor, scripting engine, .. monkey model. So much functionality comparing it with irc clients is not fair.


I would ship a daemon/service that makes use of the user installed browser, if a Web interface must be.


And you would then be back to debugging small intricate differences across browsers, which is what people ship Electron to avoid.


Since I don't want to be part of Chrome marketing force, that is a very good thing to do.

Either go native or Web standards.


That's nice technically, but awful in terms of usability.


Only if the developer doesn't know any better.

It can replicate Electron UI/UX without the bloat or Chrome marketing.


Why?


Would WASM solve the performance issue? One can imagine writing a webview GUI in a compiled language in order to get the speed and size benefits.


No, that would be worse actually. Imagine a circumstance where you need to use a library to fetch some network data that you can't do in a browser. Now you have to import the whole data stream via text serialize/deseralize into the browsers sandbox.

Wasm is also quite slower and bulkier because you'd have to compile your entire runtime into wasm, and then have it in the browser.




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

Search: