The cost of native desktop development
In 2015 building a cross-platform desktop application means dealing with three distinct ecosystems: Windows with its Win32 or WPF APIs, macOS with Cocoa and Objective-C, Linux with GTK or Qt. Each platform requires specific expertise, dedicated toolchains and separate development cycles. Existing cross-platform frameworks — such as Qt and Java Swing — offer portability but with interfaces that often feel foreign to each operating system’s native conventions.
Meanwhile, the web has developed an ecosystem of tools and libraries for building user interfaces that surpasses in richness that of any desktop platform. GitHub decides to bring that ecosystem to the desktop.
Chromium and Node.js in a single runtime
Electron — originally called Atom Shell, born as the foundation for the Atom editor — combines two components: Chromium for rendering the user interface and Node.js for operating system access. The application is written in HTML, CSS and JavaScript, the same technologies as the web, but runs as a native desktop application with access to the filesystem, system notifications, menus and the taskbar.
The architecture is divided into two processes: the main process manages the application lifecycle and system operations through Node.js; the renderer processes display the user interface through Chromium. The two communicate via a built-in IPC (inter-process communication) system.
A familiar ecosystem
For web developers, Electron eliminates the barrier to entry for desktop development. The same tools are used — npm for dependencies, DevTools for debugging, React or Angular for the interface — in a context that offers capabilities impossible in the browser: local filesystem access, operating system integration, background process execution, communication with local hardware.
The application is distributed as a single installable package for each platform. Electron Packager and Electron Builder automate the creation of installers for Windows, macOS and Linux from the same source code.
The trade-off between speed and resources
Electron adoption grows rapidly: Visual Studio Code, Slack, Atom, Discord are among the most visible applications built on this platform. The advantage is tangible — a single team with web skills produces an application for three operating systems — but the trade-off is equally real: every Electron instance embeds a complete copy of Chromium, with RAM consumption and disk space significantly higher than an equivalent native application. For many organisations, development speed and access to the web ecosystem justify the resource cost.
Link: electronjs.org
