7 ms·
> More seriously, this is an excellent proof-of-concept that a Slack client does not need to use hundreds of MB of RAM and consume most of a modern CPU core to
by rvanmil 7y ago
> More seriously, this is an excellent proof-of-concept that a Slack client does not need to use hundreds of MB of RAM and consume most of a modern CPU core to provide its basic functionality.
If you’re so sure that this is possible, then where is the Electron competitor which allows us to build cross platform applications like this, with the same levels of productivity and a consistent and decent user interface?
No one needs to be convinced that a native Slack client for each platform would be much better, I wish they would build those clients. The problem is most companies can’t reasonably justify the costs of building multiple native clients when a single cross platform one is good enough.
- bonzini 7y agoQt and to some extent GTK+ come close. GTK+ can be programmed in Vala which is a fine language that transpiles to C and supports idioms such as asynchronous programming.
- marton78 7y agoThat's cross platform for Windows, Mac and Linux, but what about Web, Android and iOS?
- tjoff 7y agoYou do not want the same UI on desktop and mobile.
- shakna 7y agoIgnoring that you probably _don't_ want the same interface across all of those... Qt, as well as Windows, macOS and Linux actually can do Android [0] and iOS [1], and Web is halfway there [2]. [0] https://doc.qt.io/qt-5/android.html https://doc.qt.io/qt-5/android.html [1] https://doc.qt.io/qt-5/ios.html https://doc.qt.io/qt-5/ios.html [2] https://wiki.qt.io/Qt_for_WebAssembly https://wiki.qt.io/Qt_for_WebAssembly
- danShumway 7y agoI just want to step in quick to advocate. Please do not use Qt for the web. Their web export tools aren't just unfinished, they're actively hostile to web paradigms. The finished product doesn't render to the DOM, it's completely screenreader inaccessible, it overrides browser preferences. In a lot of ways, Qt on the web is even worse than Flash was. You know all of the arguments against Electron that people trot out about how it's not real native, and it doesn't follow the right UX conventions or paradigms? Qt on the web is exactly like Electron on native, except way worse and without any sign that it's going to improve, because fundamentally Qt is structured around the idea that it should be able to spit out a binary blob of pixels instead of hooking into web-native primitives like the DOM. Look into something that's showing more promise, like .NET and Razor. The Rust community is also doing some good work here, although I don't know that they have any UI frameworks that are mature enough to be reliable in an enterprise setting. These aren't true cross-platform efforts yet, since they're still forcing you to think about HTML. But if I was going to bet on any project ending up with a real cross-platform solution that felt good on the web, some kind of export option from an Open Source Windows Forms or similar is probably what I would bet on. Either Microsoft or (possibly) the Rust community are the two parties that I think are most likely to end up producing a true native UI toolkit that can actually export to the web in a usable, acceptable way.
- Kipters 7y agoXamarin and Uno Platform
- leadingthenet 7y agoThat's exactly what your users don't want you to do!
- mmariani 7y agoBeeware [0] does it too, natively in python. The architecture and code base are very nice as well. [1] [0] http://www.beeware.org http://www.beeware.org [1] https://dan.yeaw.me/posts/gui-widget-for-beeware/ https://dan.yeaw.me/posts/gui-widget-for-beeware/
- Const-me 7y ago> Qt and to some extent GTK+ come close Both are C++: developers are more expensive to hire, and stuff takes more time to develop and debug. I'm proficient in C++ (programming for living since 2000), but I wouldn't pick the language for 2D GUIs in 2019. > GTK+ can be programmed in Vala Picking a non-mainstream languages is risky. Harder to find developers. Way more likely to find bugs in the toolchain and these can easily cost weeks to fix.
- bonzini 7y agoYou can also write GTK+ in JavaScript for that matter, or Python. Vala is a very underrated language though and it should be very easy for a good JavaScript programmer to pick it up.
- Snetry 7y agoEnough languages have bindings for GTK or Qt to make it viable
- kleiba 7y agobut I wouldn't pick the language for 2D GUIs in 2019 Which one would you recommend?
- Const-me 7y agoI mostly program for Windows and use C# for the GUI. Cross-platform story is complicated, though. I have good experience creating a custom GUI framework for embedded Linux: drm/kms, gles, NanoVG, [DllImport], everything on top is custom C# code in .NET core 2.2. But that approach is not for everyone. I only needed 10-15 screens with simple GUI on them, it’s a 5” touchscreen with no other user-facing devices. Creating more advanced UX this way would consume too much time. There’re Avalonia and Xamarin. Didn’t used them at that time because I needed full-screen GUI for a single-application Linux, without any desktop environments or user mode OS components. For desktops and especially mobile apps they might work OK. It’s unpopular opinion here, but I think Electron is not that bad for GUI, esp. when writing TypeScript instead of JS. I think it’s similar story to Unity3D or PHP: low entry barrier attracted inexperienced programmers, then the whole ecosystem is judged based on the output of these inexperienced people.
- codedokode 7y agoWindows 3.1 apps are somewhat cross-platform because they can be run with Wine on Linux.
- gdxhyrd 7y agoIndeed. This point is usually missed. You can even run Windows apps in BSD and macOS.
- YokoZar 7y agoIt's even better: 64-bit Windows doesn't support 16-bit Win 3.1 apps anymore, but you can still run them via Wine on the Linux subsystem.
- AnIdiotOnTheNet 7y agoIt should be noted that WineVDM[0] will allow you to run 16-bit Windows applications on Windows without the Linux subsystem. [0] https://github.com/otya128/winevdm https://github.com/otya128/winevdm It would have been relatively straightforward for Microsoft to support 16-bit on 64-bit, but they decided not to. I can't help but feel that that is just more evidence that whoever is running Windows development these days hates everything that used to make it a good desktop.
- muststopmyths 7y ago64-bit Windows has never supported 16-bit. This has nothing to do with "whoever is running Windows development these days" Back when 64-bit Windows came out (with XP and Server 20003), the adoption was pretty small since most applications were not 64-bit and did not need 64-bit address spaces. Microsoft saw the opportunity to kill at least one backward compatibility burden by not even trying to support 16-bit for x64. They figured, rightly, that by the time x64 became widespread, 16-bit would be obsolete.
- AnIdiotOnTheNet 7y ago> 64-bit Windows has never supported 16-bit. Don't believe I said otherwise. > This has nothing to do with "whoever is running Windows development these days" > Microsoft saw the opportunity to kill at least one backward compatibility burden by not even trying to support 16-bit for x64. These two statements are at odds. Microsoft used to take compatibility extremely seriously. It would have been relatively trivial to allow 16-bit applications to run, and obviously there is desire to do so since WineVDM exists, they just arbitrarily decided not to. I suspect this is because they've become infected with developers who use Linux a lot and think nothing of breaking compatibility every release, let alone in cases like this.
- j88439h84 7y agoIt's Beeware. https://beeware.org/ https://beeware.org/ > Write your apps in Python and release them on iOS, Android, Windows, MacOS, Linux, Web, and tvOS using rich, native user interfaces. Multiple apps, one codebase, with a fully native user experience on every platform.
- gattilorenz 7y agoThis sounds great, but it seems there's no out-of-the-box support for a rich text textbox? I have a python script that I want to deploy as self-contained app for windows and osx with a gui. Finding a framework that works, is decent to use, doesn't need hundreds of MBs of dependencies, and has rich text support is...not easy.
- zoom6628 7y agoHave a look at nuitka for compiling your script to a binary.
- gattilorenz 7y agoThanks, I'll try it! I was using pyinstaller atm. I'm still trying to figure out if there's a GUI that supports different text with mixed colors and features out of the box, and that's not horribly broken in OS X
- bluedino 7y agoIn the old days, you would just go on AOL's Windows programming section, find a shareware rich text control, and use that.
- gattilorenz 7y agoIn the old days, I would do it in Delphi and have the controls already in my toolbox :) I was actually thinking of giving it a go, but the idea of a Python backend and a Delphi frontend is as attractive as recoding everything in ASM.
- itronitron 7y agoWhat are your criteria for something being an Electron competitor?
- rvanmil 7y agoIt was more or less a rethorical question (I guess that’s why I’m being downvoted), because there is no competitor. If there was, then Electron wouldn’t be so extremely popular in the first place, and we’d see a lot more popular apps made with all the tools mentioned in the other replies to my post.
- BubRoss 7y agoYou are being downvoted because the idea that electron is the only way to get cross platform GUIs is absurd and comes from inexperience and a lack of research. FLTK, Juce and Qt are just some of the options for creating cross platform UIs that end up being much smaller and MUCH faster than electron. Electron is popular because people learn javascript and don't want to learn C++. I can't completely fault this mentality for toy programs, but at some point the false sweeping statements get pretty old.
- laurent123456 7y agoIt's weird to assume that developers who use Electron do so because they are ignorant, incompetent and lazy. The truth is, everybody knows about Qt, GTK and so on, and everybody knows Electron is heavy but you have to be realistic. As a company do you want to spend that much money hiring a ton of C++ developers over a much longer period of time, or do you go for the solution which, while not ideal, allows you to develop a cross platform app in a much shorter time? These days many people run Electron apps without even knowing it, showing that it's an ok solution.
- BubRoss 7y ago> It's weird to assume that developers who use Electron do so because they are ignorant, incompetent and lazy. I don't think I said all that > As a company do you want to spend that much money hiring a ton of C++ developers over a much longer period of time, This I think is a big assumption. Making a GUI isn't really that difficult. Most of the time in a program doesn't go into making the actual UI. I never hear someone who is experienced in making UIs say that electron saves them so much time, it is always people assuming it takes an army of C++ people to do what one person can do with electron, which is bizarre, especially over the course of something that is more than a prototype.
- asjw 7y agoRedlang
- benibela 7y agoThere is Delphi and Lazarus as open-source clone of it Lazarus can use the Windows API on Windows, gtk/qt on Linux, and carbon/cocoa on Mac. There is also a custom drawn mode that draws the GUI directly rather than using platform apis. That also runs on Android, but it not maintained anymore, so only up to Android 5 or something Delphi is supposed to run on Android and iOS. And Delphi 1 ran on Windows 3.1, so you could have used the same GUI since then
- noonespecial 7y agoThere is Delphi and Lazarus as open-source clone of it Shhh! Ixnay on the Lazarusay. If people find out, I'll lose my magical secret weapon for blasting out little windows gui apps. Seriously though, if you ever find yourself needing a few buttons on a windows desktop that do simple things, Lazarus is amazing for whipping that up in a few minutes and still looking professional.
- AnIdiotOnTheNet 7y agoAgreed. I'm not a huge fan of Pascal, but it's better than JS and Lazarus makes knocking up a simple GUI trivially easy.
- benibela 7y agoNah, when people find out it is Pascal, they run away. Can't type begin and end, such words are just too long
- scarface74 7y agoYes, because Slack is one man shop that can’t afford to hire one or two Windows, Mac, and Linux developers.
- archi42 7y agoActually, s/Slack/Tidal/ if you want to add insult to injury. Electron app for Windows and Mac (but well, nice features overall). However, no Linux build.
- kelnos 7y agoSlack does have (very-long-time-beta) Linux build[0], though I personally prefer to just use Slack through my browser instead of suffering through an Electron app. [0] https://slack.com/downloads/linux https://slack.com/downloads/linux
- folmar 7y agoThe web version work also well in Firefox, so you don't need to give all your RAM. Slack calls don't work reliably in Chrome/Electron on linux anyway, so no loss here.
- artificial 7y agoHere’s a free lightweight native Mac client (with dark mode oooOooo) https://www.sblack.online/ https://www.sblack.online/
- deleted 7y ago[deleted]