Electron

Electron — MIT 许可的框架,用于用 JavaScript、HTML、CSS、Chromium 和 Node.js 构建跨平台桌面应用

About Electron

Electron is an open-source framework for building cross-platform desktop apps with JavaScript, HTML, and CSS. The official site says it embeds Chromium and Node.js to bring JavaScript to the desktop, and it supports macOS, Windows, and Linux.

Electron is widely used for:

  • desktop applications with rich user interfaces
  • developer tools and code editors
  • messaging and collaboration apps
  • cross-platform utilities
  • apps that combine web UI with native desktop capabilities

Created by: GitHub First released: 2013 Primary languages: JavaScript, C++, Objective-C++ License: MIT License

Electron became popular because it lets teams build desktop software with web technologies they already know. Instead of maintaining separate native stacks for each operating system, developers can ship one application codebase that runs across platforms. The Electron site highlights its cross-platform support and its open-source nature under the OpenJS Foundation.

Key strengths include:

  • Shared web stack using HTML, CSS, and JavaScript
  • Cross-platform distribution across macOS, Windows, and Linux
  • Node.js integration for filesystem, process, and system-level access
  • Chromium rendering for modern UI capabilities
  • Large ecosystem of tooling such as Electron Forge and Electron Fiddle.

Common Use Cases

Developer Tools

Electron is especially common for editors, IDEs, terminals, build tools, and internal developer utilities.

Communication Apps

Chat clients, meeting apps, and collaboration tools often use Electron because it combines fast UI development with desktop integration.

Business Software

Many desktop business applications use Electron for account management, dashboards, workflow tools, and cross-platform consistency.

Cross-Platform Wrappers

Teams sometimes use Electron to wrap an existing web application into a desktop package while keeping a shared codebase.

Internal Utilities

Electron is also useful for shipping internal apps quickly when the team wants a browser-style UI and native desktop packaging.

Technical Notes

Electron packages Chromium and Node.js together, which means the renderer process can handle the UI while the main process can access system features and native APIs. This architecture is why Electron apps can feel like web applications while still integrating with the operating system.

Important concepts include:

  • main and renderer processes
  • IPC between UI and native logic
  • packaging and auto-update workflows
  • native menus, dialogs, notifications, and file access

License Information

Electron is distributed under the MIT License.

The current Electron license notice is:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
Copyright (c) Electron contributors Copyright (c) 2013-2020 GitHub Inc.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

If you redistribute Electron itself or bundle it into another product, keep the license notice and attribution information with your distribution.

How to Attribute Electron in Your Project

In README.md

1
This project uses [Electron](https://www.electronjs.org/) © Electron contributors, MIT License.

In About / Credits page

1
2
Electron - Copyright Electron contributors - MIT License
https://github.com/electron/electron/blob/main/LICENSE
1
2
Electron desktop framework, MIT License
Copyright Electron contributors

Resources