5 ms·
I wonder why there is no runtime package for all your electron applications, so you only have to install the runtime once and every app can depend on this runti
by 0XAFFE 9y ago
I wonder why there is no runtime package for all your electron applications, so you only have to install the runtime once and every app can depend on this runtime. This would greatly reduce download sizes of individual applications.
- Drakim 9y agoI assume because it would defeat the intention of electron, since the entire point is to "magically" make your webapp into a standalone application with no dependencies. Just download and start it up, like any application. Whether this is wise is another question.
- greglindahl 9y ago... and with this sort of magic, I expect that all of the applications that I download are going to have completely different versions of all of the dependencies, so, ... there's no sharing anyway.
- callumlocke 9y agoBecause the market-proven reality is most end users don’t care about 100MB download sizes, and they do care about simplicity.
- nukeop 9y ago100 MB is nothing. My electron program is only 35 MB in size. Most people have multiple 1TB disks now.
- imtringued 9y agoOr people have laptops and because they don't waste it on bloated crap like Windows and instead use linux a single 256NVMe SSD is enough. I use 50GB right now for the Linux installation with everything I could possibly need for work and another 50GB for two empty Windows VMs with nothing in them except a browser.
- amiga-workbench 9y agoMost people? At the bottom of the windows laptop barrel you now see laptops with 32/64gb of EMMC storage and the guts of an Intel bay trail tablet. These are acceptable for people who use their computer as a Facebook machine but "modern" software really taxes them.
- JetSpiegel 9y agoEach runtime can be a different electron version and have different combination of npm packages. It's the Wild West, without a standard library and tons of options for the same problems.
- dspillett 9y agoBut if they could at least share the Chrome and Node bulk? They'd still have to have their own copy in their address-space so you'll not save RAM but you might save a chunk of disk space (handy when working on a tablet or small laptop with a small eMMC drive) and download time. Of course versioning will be an issue so you might still need multiple versions for compatibility reasons. You might need a copy of 1.6.16, 1.6.17, 1.8.0, 1.8.2, and 2.0.0 to server your collection of apps. How to solve that problem would require some thought. When a user starts an app, if the version it is built against (or one it is otherwise marked as compatible with) isn't present do you warn the user and refuse to run, warn the user but run with the next best thing as it might just work, or automatically kick off a download? For systems where people are used to having a package manager this can be relatively transparent (apt install myElectronApp, pulls a versioned electron package if needed at the same time) but less so on Windows. Perhaps it would be to complex (so potentially bug ridden) for the savings involved. Filesystem block-level deduplication might help the space issue, though not the download issue.
- quantummkv 9y agoThis will open a new can of worms. A new electron app uses some new feature that updates your runtime. But unfortunately the runtime update to make one app work breaks some other app. The current model isolates the runtime to every app. The download size may be big but I have a guarantee that my app will work without interference from others. Honestly, that guarantee justifies the binary size for me.
- dingo_bat 9y agoOr electron runtime can do the sane thing and be backward compatible for a few version numbers. It's basic API stability.