I’m looking for a programming language that can help me build a desktop application for Windows, macOS, and Linux that’s not big but not small either. Additionally, I’d like to be able to build a website with the same language. I’ve been considering Ruby, Python, Golang and JavaScript. Python seems to be mainly used for scripting and ai, so I’m not sure if it’s the best fit. JavaScript has a lot of negative opinions surrounding it, while Ruby sounds interesting. Can anyone recommend a language that meets my requirements?
You can count Ruby out immediately. Terrible language.
Also replace JavaScript with Typescript. It’s strictly superior.
I don’t think Go has any mature GUI libraries.
For desktop GUI your main options are:
For the web frontend you basically want Typescript. For the backend you can use literally any language.
I would recommend Electron for the GUI and Typescript for the web frontend and Electron GUI. It means you can use the same language everywhere and you won’t need to even implement the same program twice.
If you’re worried about the download size / RAM usage you can look into Tauri which uses your OS’s browser engine. I’ve never used it though.
Regarding tauri: One and a half years ago I looked into it as a potential alternative to using electron.
Back then I had to decide against it for my use case, because when the goal is that it’s a cross platform app, then one has to make sure that whatever “webview version” is used on all target OS, they all have to support the features one needs re one’s own app codebase. Back then I needed some “offscreen canvas” feature that chromium supported (hence electron), but which
webkit2gtk
(used on Linux) didn’t at the time.https://tauri.app/v1/references/webview-versions/
So it’s not always easy to give a clear recommendation on using tauri over electron. One really has to get somewhat clear on what kind of “webview requirements” the resp. app will have.
But I do hope this will (or maybe already is) less of an issue in upcoming years (things are moving fast after all).
wow.
Ever tried to follow a large Ruby codebase like Gitlab? Absolutely nightmare. Not only does it not have type annotations, so you can’t follow code by clicking, but you can’t even follow it by grepping because Rubyists seem to love generated identifiers. Even the syntax of the language makes grepping worse, e.g. the lack of brackets prevents you from grepping for function calls like
foo(
.