News for hackers. Stuff that matters.
Re:Electron 7.0 by headcanon on Thursday October 24, 2019 @01:29PM (#21346942)
Every time Electron is mentioned I bust out the popcorn for the inevitable hate spewed towards it:

"Javascript is a terrible language and no one should use it"

"Separate instances of chrome for every app is dumb and consumes too much memory"

"Qt is amazing and elegant and desktop-native. Why isn't everyone just using Qt?"

Re:Electron 7.0 by Hendrikto on Thursday October 24, 2019 @01:33PM (#21346992)
> "Separate instances of chrome for every app is dumb and consumes too much memory"

That one is true though. Different Electron apps could at least share the runtime.

Re:Electron 7.0 by paulryanrogers on Thursday October 24, 2019 @01:44PM (#21347126)
Except they cannot, Chromium (or is it Blink?) changes too frequently to reliably code for one version and expect backward compatibility of future releases. Electron versions could be shared libraries... except again BC breaking releases proliferate.
Re:Electron 7.0 by hanniabu on Thursday October 24, 2019 @02:08PM (#21347378)
Why can't it be based of Chrome's version number? If you know the version number at the time of release then you can say only use the same runtime if there's only a revision version difference, else you can use it's own run time. That packaged with auto-updates for the app to that developers can push updated builds every month or so should be fine.
Re:Electron 7.0 by shaki-dora on Thursday October 24, 2019 @01:57PM (#21347270)
Websites manage to target different versions, and browsers, and even device classes just fine.
Re:Electron 7.0 by diffeomorphism on Friday October 25, 2019 @06:36AM (#21353574)
Except they chose not to, preferring to allow for frequent breaking changes. This makes it easier for devs to make these rapid changes with all the cost/overhead payed by you.
Re:Electron 7.0 by kodablah on Thursday October 24, 2019 @04:01PM (#21348597)
With their multi-process approach, you'd have separate processes even when sharing the runtime to the point that sharing the DLLs likely has minimal benefit. It's the equivalent of running firing up Chrome twice w/ two different user profile dirs...shared libs, but no obvious perf advantage over two separate Chrome installs.
Re:Electron 7.0 by judge2020 on Thursday October 24, 2019 @01:38PM (#21347047)
I imagine the different electron versions and different Chrome versions would make this hard without breaking things. Maybe a config option for "allow chromium between versions x and y" would solve this.
Re:Electron 7.0 by Hendrikto on Thursday October 24, 2019 @01:40PM (#21347071)
Shouldn‘t Chrome be backwards compatible? I would hope so at least.
Re:Electron 7.0 by judge2020 on Thursday October 24, 2019 @01:48PM (#21347182)
Most electron projects I've seen have used webpack targeting ES2017 or earlier anyways which makes this unlikely, but if you compile for ESnext (or don't compile at all) and use a new V8 feature, you wouldn't want Chrome 69 running your app and getting stuck on old V8 not being able to use the new feature.
Re:Electron 7.0 by pawelk on Thursday October 24, 2019 @05:22PM (#21349319)
Maybe it should, but it's not always the case. As a front end dev I have to fix issues related to bugs introduced by browser uptades every now and then and usually it's Chrome. On the web it's easy, deploy a fix and it's live. With a desktop app I can't even imagine the logistics involved.
Re:Electron 7.0 by mikepurvis on Thursday October 24, 2019 @01:39PM (#21347061)
Is that really possible? I feel like it would only work with considerable engineering effort, and even then, probably only if the bundled Chrome instances were all exactly the same version.
Re:Electron 7.0 by michaelmrose on Thursday October 24, 2019 @01:47PM (#21347168)
This is literally how every gui library on planet earth works. Developers all build against a particular recent released version with all apps in the system expected to build against a small number of recent versions.

If this is hard maybe its because the browser isn't a very good runtime to build against.

Re:Electron 7.0 by mikepurvis on Thursday October 24, 2019 @03:51PM (#21348519)
Right, but those systems are set up from the get-go with that usage pattern in mind, where you have an expectation of ABI compatibility and the underlying libraries as a shared resource.

The expectation with Electron has always been that you bundle a copy of it with your app, so that you're always targeting exactly that version.

Re:Electron 7.0 by pmarreck on Thursday October 24, 2019 @06:11PM (#21349710)
1) Log into Slack in Chrome

2) Log into Discord in Chrome

3) Log into <insert application here> in Chrome

Problem solved?

Re:Electron 7.0 by bhhaskin on Thursday October 24, 2019 @06:42PM (#21349945)
Swap Firefox for Chrome and you are golden.
Re:Electron 7.0 by rosybox on Thursday October 24, 2019 @02:50PM (#21347893)
The problem with Qt I have is how incredibly expensive it is. Sure it's free if you want to build something open source, but you know some of us have to also make money to pay for being alive and it's hard to bootstrap an application if you have to pay $5,508 up front, per developer, and then again on an annual basis.
Re:Electron 7.0 by pritambaral on Thursday October 24, 2019 @03:24PM (#21348274)
You can use Qt with closed source software, under the LGPL license that you don't have to pay for. Only the binaries that have Qt code need to be open. Don't statically link Qt libs into your closed-source code and you're good.
Re:Electron 7.0 by sroussey on Thursday October 24, 2019 @04:08PM (#21348656)
And put that in an app store?
Re:Electron 7.0 by hellofunk on Thursday October 24, 2019 @04:22PM (#21348770)
Yes, even on iOS.
Re:Electron 7.0 by kej on Thursday October 24, 2019 @05:02PM (#21349134)
The LGPL requires end users to be able to view and modify the LGPL portion of the derivative work. Does iOS give end users that level of access to apps? (honest question, my outsider's impression of Apple is that they have stuff locked down more than that)
Re:Electron 7.0 by ksherlock on Thursday October 24, 2019 @05:56PM (#21349607)
There was an iOS email client a few years back that used some LGPL components. They complied by providing the object files so you could, in theory, re-link (and re-sign) using your own updated LGPL library.

Ahh, here we go:

https://news.ycombinator.com/item?id=4302517

https://web.archive.org/web/20140325063249/http://sprw.me/lg...

Re:Electron 7.0 by vunie on Thursday October 24, 2019 @09:19PM (#21350900)
Let me preface by emphasizing that IANAL, but I believe the issue isn't with the software vendor and is instead with the distribution platform (i.e Apple).

The LGPLv3 mandates that users be allowed to modify the parts that are licensed by this license. The TOS of the Apple App Store explicitly disallows its users from modifying software they get from it, thereby running afoul of the LGPL.

So this issue, as I understand it, is that neither the software vendor nor Apple have a license to distribute Qt on a platform that places additional restrictions on what the user may do with LGPL software. I think this is the reason why Apple removed VLC and other GPL software from their stores.

Please correct me if I got this wrong.

Re:Electron 7.0 by vunie on Friday October 25, 2019 @12:08AM (#21351789)
Cant edit my post, but here are a few links that you might find interesting:

* FSF's opinion: https://www.fsf.org/news/2010-05-app-store-compliance

* General conscious: https://apple.stackexchange.com/questions/6109/is-it-possibl...

Re:Electron 7.0 by jcelerier on Thursday October 24, 2019 @05:14PM (#21349254)
the problem with iOS was that you had to pay 99$ a year to upload apps to your own phone, which prevent use of GPL code since it removes your right to do stuff on your own hardware. Fortunately this restriction was lifted since Xcode 7 a few years ago and it's nowadays not a problem at all - there are plenty of GPL / LGPL apps on the app store. Just put the code and build instructions on github, what matters is that users can patch, rebuild and upload the patched version to their phone.
Re:Electron 7.0 by davet91 on Thursday October 24, 2019 @03:30PM (#21348343)
The core of Qt is licensed under LGPL which means you can write and ship proprietary software with it. You just need to dynamically link and provide sources for the Qt libs if a user requests it.
Re:Electron 7.0 by de_watcher on Friday October 25, 2019 @02:39AM (#21352496)
I can't fathom how do people still don't understand the licensing and keep posting FUD about it.

Every single time. How it's even possible?

No, you don't have to pay anything to build and sell your proprietary software built with Qt.

Re:Electron 7.0 by nly on Friday October 25, 2019 @04:11AM (#21352863)
I see this out of date myth on every HN page discussing Qt. The fact that people still don't know that Qt is LGPL is damaging.
Re:Electron 7.0 by inferiorhuman on Thursday October 24, 2019 @03:48PM (#21348487)
you know some of us have to also make money to pay for being alive and it's hard to bootstrap an application if you have to pay $5,508 up front, per developer, and then again on an annual basis

Are you really surviving on $5,500 annually?

Re:Electron 7.0 by zrobotics on Thursday October 24, 2019 @04:18PM (#21348735)
$5.5k annually, even in the US, is still enough money to devote a few hours per week on a paid hobby project. I'm actually working on a side-project app right now, and if it makes >5.5k/year I'd be fairly pleased.

Not enough to survive on, but as a sideline business that isn't terrible money as long as it doesn't consume 40 hours/week.

Re:Electron 7.0 by mikepurvis on Thursday October 24, 2019 @01:36PM (#21347026)
The people complaining are not the customers, they're the product. Electron isn't sold to the users running Slack and Spotify and Atom, it's sold to the developers of those things with the promise of a low-friction path for existing web devs to deploy a native-ish application on multiple platforms.
Re:Electron 7.0 by rafaelvasco on Thursday October 24, 2019 @01:34PM (#21346994)
Only second one is a really valid point;
Re:Electron 7.0 by YesSureThing on Thursday October 24, 2019 @01:33PM (#21346981)
I would use Uno.platform . C++ is also a terrible language.