12 ms·
This is a useless comparison. Once you're hosting an actual app, the content matters way more.
by xpaulbettsx 8y ago
This is a useless comparison. Once you're hosting an actual app, the content matters way more.
- saagarjha 8y agoMessages uses webviews and manages to do much of what Slack does with a tenth of the memory footprint. I still have not found any evidence for your claim that Electron and WKWebView use the same amount of memory.
- xpaulbettsx 8y agoYou're literally comparing two completely different apps. If you want to compare Apples to Apples, host 5 teams in Slack, in both Chromium and WKWebView
- ptx 8y agoWhat if I only have one team and a handful of channels, though? In that case I prefer starting with a lower constant memory overhead.
- nvr219 8y agocalm down friend
- dang 8y agoNo personal swipes on HN, please.
- _wmd 8y agoThere is of course value in comparing Messages-the-HTML-app to Slack-the-HTML-app. If they can do it in a fraction of the memory with comparable functionality, I wonder why Slack can't
- saagarjha 8y agoUnfortunately, I’m in a place where I can test your argument, so the best evidence I can give you is the personal anecdote that I run Slack in Safari rather than using the Electron app for performance reasons. It’s not quite WKWebView, but I think it’s a relatively decent approximation. With that said, I still think you’re missing the point: it’s completely possible to make a messaging app that uses significantly less memory than Slack does and does basically the same things, even if you ditch native controls (which is not something I prefer people do, for reasons other than performance, but it’s something I am willing to tolerate). Loading an entire browser with its associated baggage rather than using the platform’s native web view will almost always use more resources, because you will have bloat that is not necessary for what you are doing and some features will end up being reimplemented in Electron. Just because Slack might perform poorly in both a web view and Electron (which I still believe is not equally poorly), does not mean that it could not perform well at all. There are multiple issues here.
- mikewhy 8y agoHere's a simple comparison using nativefier (electron based single-site-browsers) vs something using WKWebView: https://imgur.com/oG2Dm5y https://imgur.com/oG2Dm5y Both are playing low-quality HTML5 video. For any sites I could think of, the memory usage, thread count, CPU time, and idle wake ups were considerably smaller using WKWebView. The disk usage was also crazy smaller, as is expected. ~122MB for nativefier vs ~14MB for WKWebView (and a lot of that is due to being written in Swift).
- giornogiovanna 8y agoEven if memory usage is the same, there's a world of a difference when it comes to executable size, and for most Electron apps, I doubt the content will outweigh the runtime.
- xpaulbettsx 8y agoI don't find disk space worth optimizing for in 2018. For $2 you can buy a USB Thumbdrive that will hold every Electron app you'll ever use.
- yladiz 8y agoIt's opinions like this that cause first day downloads for new games like Red Dead Redemption 2 to be 55GBs. In the case of an Electron app disk space might not matter as much, but it's absolutely worth optimizing in 2018, at least because not everyone has high speed connections (e.g. in Germany, a lot of infrastructure is built around DSL, which obviously doesn't get great speeds).
- ianhawes 8y agoYou’re comparing apples to oranges. 3D models vs. app code. You will be hard pressed to find any Electron app that exceeds 200 MB in disk space. Most are ~50 MB. Overall in 2018 that is not a big concern. In gaming, high definition graphics are going to result in massively larger files. That’s not going to change anytime soon and no gaming company will prioritize a small download over better graphics.
- yladiz 8y agoYes I know, and the size of an Electron app versus a AAA game is sometimes 3 orders of magnitude in difference, which is why I pointed out that even a "small" app that's 100MB is still a lot to download on a limited speed connection.
- josephg 8y ago> You will be hard pressed to find any Electron app that exceeds 200 MB in disk space. Most are ~50 MB. Huh? Looking at my applications folder right now: Atom 1.31: 822mb Daedalus 0.8: 265mb Mist 0.9.2: 186mb Neon 0.0.7: 180mb Patchwork: 185mb Riot 0.11.4: 160mb VS Code: 193mb The electron framework alone is 117mb on MacOS. Honestly, how many copies of that do I need?
- ynniv 8y agoThere is a long history of sophisticated applications being written in less than a hundred megabytes, so where's the budget going? Hero images?
- will4274 8y agoYou made the original claim. Do you have any data to back it up?