Skip to main content

Electron 25.0.0

· 7 min read

Electron 25.0.0 已经发布!它包括对 Chromium 114、V8 11.4 和 Node.js 18.15.0 的升级。请往下阅读了解更多详情!

🌐 Electron 25.0.0 has been released! It includes upgrades to Chromium 114, V8 11.4, and Node.js 18.15.0. Read below for more details!


Electron 团队很高兴地宣布发布 Electron 25.0.0!你可以通过 npm 使用 npm install electron@latest 安装,或从我们的发布网站下载。请继续阅读以了解此次发布的详细信息。

🌐 The Electron team is excited to announce the release of Electron 25.0.0! You can install it with npm via npm install electron@latest or download it from our releases website. Continue reading for details about this release.

如果你有任何反馈,请通过 Twitter 与我们分享,或加入我们的社区 Discord!你可以在 Electron 的 问题追踪器 中报告错误和功能请求。

🌐 If you have any feedback, please share it with us on Twitter, or join our community Discord! Bugs and feature requests can be reported in Electron's issue tracker.

22.x.y 持续支持

🌐 22.x.y Continued Support

如在《告别 Windows 7/8/8.1》(https://www.electronjs.org/blog/windows-7-to-8-1-deprecation-notice) 中所述,Electron 22(Chromium 108)的计划终止支持日期将从 2023 年 5 月 30 日延长至 2023 年 10 月 10 日。Electron 团队将继续为该版本提供安全修复的回溯更新,直至 2023 年 10 月 10 日。10 月的支持日期是根据 Chromium 和 Microsoft 的延长支持日期确定的。自 10 月 11 日起,Electron 团队将仅支持最新的三个稳定主版本,这些版本将不再支持 Windows 7/8/8.1。

🌐 As noted in Farewell, Windows 7/8/8.1, Electron 22's (Chromium 108) planned end of life date will be extended from May 30, 2023 to October 10, 2023. The Electron team will continue to backport any security fixes that are part of this program to Electron 22 until October 10, 2023. The October support date follows the extended support dates from both Chromium and Microsoft. On October 11, the Electron team will drop support back to the latest three stable major versions, which will no longer support Windows 7/8/8.1.

E25(2023年5月)E26(2023年8月)E27(2023年10月)
25.x.y26.x.y27.x.y
24.x.y25.x.y26.x.y
23.x.y24.x.y25.x.y
22.x.y22.x.y--

显著变化

🌐 Notable Changes

  • 在 Electron 的 net 模块中实现了 net.fetch,使用了 Chromium 的网络栈。这与 Node 的 fetch() 不同,后者使用 Node.js 的 HTTP 栈。参见 #36733#36606
  • 添加了 protocol.handle,它取代并弃用 protocol.{register,intercept}{String,Buffer,Stream,Http,File}Protocol#36674
  • 为了与 Chromium 以及微软的 Windows 7/8/8.1 弃用计划保持一致,扩展对 Electron 22 的支持。更多详细信息请参见本文博客文章末尾。

Electron 24.0.0

· 6 min read

Electron 24.0.0 已经发布!它包括对 Chromium 112.0.5615.49、V8 11.2 和 Node.js 18.14.0 的升级。请往下阅读了解更多详情!

🌐 Electron 24.0.0 has been released! It includes upgrades to Chromium 112.0.5615.49, V8 11.2, and Node.js 18.14.0. Read below for more details!


Electron 团队很高兴地宣布发布 Electron 24.0.0!你可以通过 npm 使用 npm install electron@latest 安装,或从我们的发布网站下载。请继续阅读以了解此次发布的详细信息。

🌐 The Electron team is excited to announce the release of Electron 24.0.0! You can install it with npm via npm install electron@latest or download it from our releases website. Continue reading for details about this release.

如果你有任何反馈,请通过 Twitter 与我们分享,或加入我们的社区 Discord!你可以在 Electron 的 问题追踪器 中报告错误和功能请求。

🌐 If you have any feedback, please share it with us on Twitter, or join our community Discord! Bugs and feature requests can be reported in Electron's issue tracker.

Electron 十周年 🎉

· 18 min read

🌐 10 Years of Electron 🎉

electron/electron 仓库的第一次提交是在 2013 年 3 月 13 日[^1]。

🌐 The first commit to the electron/electron repository was on March 13, 2013[^1].

Initial commit on electron/electron by @aroben

经过10年和1192名独立贡献者的27,147次提交后,Electron 已成为当今构建桌面应用最受欢迎的框架之一。这个里程碑是一个完美的机会,让我们庆祝并回顾迄今为止的旅程,同时分享我们在此进程中所学到的经验。

如果没有每一位为项目付出时间和努力的人,我们今天不会站在这里。虽然源代码提交总是最显眼的贡献,但我们同样需要感谢那些报告错误、维护用户模块、提供文档和翻译,以及在网络空间参与 Electron 社区的人。每一份贡献对我们这些维护者来说都是无价的。

🌐 We would not be here today without everyone who has dedicated their time and effort to contribute to the project. Although source code commits are always the most visible contributions, we also have to acknowledge the effort of folks who report bugs, maintain userland modules, provide documentation and translations, and participate in the Electron community across cyberspace. Every contribution is invaluable to us as maintainers.

在我们继续阅读博客文章剩下部分之前:谢谢你。❤️

我们是怎么走到这一步的?

🌐 How did we get here?

Atom Shell 是作为 GitHub Atom 编辑器 的基础而构建的,该编辑器于 2014 年 4 月推出了公开测试版。它从零开始开发,作为当时可用的基于网络的桌面框架(node-webkit 和 Chromium 嵌入式框架)的替代方案。它有一个杀手级功能:嵌入 Node.js 和 Chromium,为 web 技术提供强大的桌面运行环境。

在一年内,Atom Shell 在功能和受欢迎程度上都开始迅速增长。大公司、初创企业以及个人开发者都开始用它来构建应用(一些早期采用者包括 SlackGitKrakenWebTorrent),项目也因此被恰当地重命名为 Electron

🌐 Within a year, Atom Shell began seeing immense growth in capabilities and popularity. Large companies, startups, and individual developers alike had started building apps with it (some early adopters include Slack, GitKraken, and WebTorrent), and the project was aptly renamed to Electron.

从那时起,Electron 就一发不可收拾,持续发展。以下是我们每周下载量的变化情况,由 npmtrends.com 提供:

🌐 From then on, Electron hit the ground running and never stopped. Here’s a look at our weekly download count over time, courtesy of npmtrends.com:

Electron weekly downloads graph over time

Electron v1 于 2016 年发布,承诺提供更稳定的 API 以及更好的文档和工具。Electron v2 于 2018 年发布,推出了语义化版本控制,使 Electron 开发者更容易跟踪发布周期。

🌐 Electron v1 was released in 2016, promising increased API stability and better docs and tooling. Electron v2 was released in 2018 and introduced semantic versioning, making it easier for Electron developers to keep track of the release cycle.

到了 Electron v6,我们改为每 12 周发布一次重大版本,以与 Chromium 的发布节奏保持一致。这一决策意味着项目思维方式的转变,将“拥有最新的 Chromium 版本”从可有可无变为了优先事项。这减少了升级之间的技术债务,使我们更容易保持 Electron 的更新和安全。

🌐 By Electron v6, we shifted to a regular 12-week major release cadence to match Chromium’s. This decision was a change in mentality for the project, bringing “having the most up-to-date Chromium version” from a nice-to-have to a priority. This has reduced the amount of tech debt between upgrades, making it easier for us to keep Electron updated and secure.

从那以后,我们就像一台运转良好的机器,每当 Chromium 发布稳定版时,我们也会在同一天发布新的 Electron 版本。到了 2021 年 Chromium 将发布周期加快到 4 周时,我们能够轻轻一耸肩,并相应地将我们的发布频率提高到 8 周。

🌐 Since then, we’ve been a well-oiled machine, releasing a new Electron version on the same day as every Chromium stable. By the time Chromium sped up their release schedule to 4 weeks in 2021, we were able to shrug our shoulders and increase our release cadence to 8 weeks accordingly.

我们现在已经在使用 Electron v23(且仍在更新中),并且仍然致力于打造最好的跨平台桌面应用运行时。即便近年来 JavaScript 开发工具蓬勃发展,Electron 仍然是桌面应用框架字段中稳定、经过实战考验的中坚力量。如今,Electron 应用随处可见:你可以用它编程(如 Visual Studio Code)、设计(如 Figma)、沟通(如 Slack)、做注意(如 Notion)——以及许多其他应用场景。我们为这一成就感到非常自豪,也感谢每一位让这一切成为可能的人。

🌐 We’re now on Electron v23 (and counting), and are still dedicated to building the best runtime for building cross-platform desktop applications. Even with the boom in JavaScript developer tools in recent years, Electron has remained a stable, battle-tested stalwart of the desktop app framework landscape. Electron apps are ubiquitous nowadays: you can program with Visual Studio Code, design with Figma, communicate with Slack, and take notes with Notion (amongst many other use cases). We’re incredibly proud of this achievement and grateful to everyone who has made it possible.

我们在此进程中学到了什么?

🌐 What did we learn along the way?

走向十周年的道路漫长而曲折。以下是一些帮助我们运营可持续大型开源项目的关键因素。

🌐 The road to the decade mark has been long and winding. Here are some key things that have helped us run a sustainable large open source project.

使用治理模型扩展分布式决策

🌐 Scaling distributed decision-making with a governance model

我们必须克服的一个挑战是,在 Electron 首次爆红之后,如何处理项目的长期方向。我们如何应对作为一个由几十名工程师组成、分布在不同公司、国家和时区的团队的情况?

🌐 One challenge we had to overcome was handling the long-term direction of the project once Electron first exploded in popularity. How do we handle being a team of a couple dozen engineers distributed across companies, countries, and time zones?

在早期,Electron 的维护者团队依赖非正式的协调方式,这对于较小的项目来说快速且轻量,但无法扩展到更广泛的协作中。2019 年,我们转向了一种治理模式,不同的工作组拥有正式的职责范围。这对于简化进程和将项目部分所有权分配给特定维护者起到了重要作用。如今,每个工作组(WG)负责的具体内容是什么?

🌐 In the early days, Electron’s maintainer group relied on informal coordination, which is fast and lightweight for smaller projects, but doesn’t scale to wider collaboration. In 2019, we shifted to a governance model where different working groups have formal areas of responsibility. This has been instrumental in streamlining processes and assigning portions of project ownership to specific maintainers. What is each Working Group (WG) responsible for nowadays?

  • 发布 Electron 版本(发布工作组)
  • 升级 Chromium 和 Node.js(升级工作组)
  • 监督公共 API 设计 (API WG)
  • 保障 Electron 安全(安全工作组)
  • 运行网站、文档和工具(生态系统工作组)
  • 社区和企业拓展(拓展工作组)
  • 社区审核(社区与安全工作组)
  • 维护我们的构建基础设施、维护工具和云服务(基础设施工作组)

差不多在我们转向治理模式的同时,我们也将 Electron 的所有权从 GitHub 转移到了 OpenJS 基金会。虽然最初的核心团队今天仍在微软工作,但他们只是构成 Electron 治理的更大协作团队的一部分。[2]

🌐 Around the same time we shifted to the governance model, we also moved Electron's ownership from GitHub to the OpenJS Foundation. Although the original core team still works at Microsoft today, they are only a part of a larger group of collaborators that form Electron governance.[^2]

虽然这个模式并不完美,但它在全球大流行和持续的宏观经济逆风中一直很适合我们。展望未来,我们计划改进治理章程,以引导我们度过 Electron 的第二个十年。

🌐 While this model isn’t perfect, it has suited us well through a global pandemic and ongoing macroeconomic headwinds. Going forward, we plan on revamping the governance charter to guide us through the second decade of Electron.

info

如果你想了解更多,可以查看 electron/governance 仓库!

🌐 If you want to learn more, check out the electron/governance repository!

社区

🌐 Community

开源项目的社区部分很难,尤其是当你的宣传团队只有十几个工程师,却穿着一件写着“社区经理”的风衣时。不过,作为一个大型开源项目,我们拥有大量用户,利用他们的力量为 Electron 构建用户生态系统是维持项目健康的一个关键部分。

🌐 The community part of open source is hard, especially when your Outreach team is a dozen engineers in a trench coat that says “community manager”. That said, being a large open source project means that we have a lot of users, and harnessing their energy for Electron to build a userland ecosystem is a crucial part of sustaining project health.

我们做了哪些工作来提升社区影响力?

🌐 What have we been doing to develop our community presence?

构建虚拟社区

🌐 Building virtual communities

参与高知名度开源项目

🌐 Participating in high-visibility open source programs

让一切自动化!

🌐 Automate all the things!

截至今天,Electron 的治理团队大约有 30 名活跃维护者。不到一半是全职贡献者,这意味着有很多工作需要分担。我们保持一切顺利运转的秘诀是什么?我们的座右铭是计算机便宜,而人类的时间宝贵。以典型工程师的方式,我们开发了一套自动化支持工具来让我们的工作更轻松。

🌐 Today, Electron governance has about 30 active maintainers. Less than half of us are full-time contributors, which means that there’s a lot of work to go around. What’s our trick to keeping everything running smoothly? Our motto is that computers are cheap, and human time is expensive. In typical engineer fashion, we’ve developed a suite of automated support tooling to make our lives easier.

非 Goma

🌐 Not Goma

Electron 核心代码库是一个庞大的 C++ 代码集合,构建时间一直是限制我们快速发布 bug 修复和新功能的因素。2020 年,我们部署了 Not Goma,这是一个为 Electron 定制的 Google Goma 分布式编译服务的后端。Not Goma 会处理授权用户机器的编译请求,并将编译进程分发到后端的数百个核心上。它还会缓存编译结果,因此其他人编译相同的文件时,只需下载预编译结果。

🌐 The core Electron codebase is a behemoth of C++ code, and build times have always been a limiting factor in how fast we can ship bug fixes and new features. In 2020, we deployed Not Goma, a custom Electron-specific backend for Google’s Goma distributed compiler service. Not Goma processes compilation requests from authorized user’s machines and distributes the process across hundreds of cores in the backend. It also caches the compilation result so that someone else compiling the same files will only need to download the pre-compiled result.

自从推出 Not Goma 以来,维护者的编译时间已经从几小时缩短到几分钟。稳定的互联网连接成为贡献者编译 Electron 的最低要求!

🌐 Since launching Not Goma, compilation times for maintainers have decreased from the scale of hours to minutes. A stable internet connection became the minimum requirement for contributors to compile Electron!

info

如果你是开源贡献者,你也可以尝试使用 Not Goma 的只读缓存,它在默认情况下随 Electron Build Tools 提供。

🌐 If you’re an open source contributor, you can also try Not Goma’s read-only cache, which is available by default with Electron Build Tools.

持续因素身份验证

🌐 Continuous Factor Authentication

持续因子认证(CFA) 是围绕 npm 的双因素认证(2FA)系统的一层自动化,我们将其与 semantic-release 结合,以管理我们各个 @electron/ npm 包的安全和自动化发布。

虽然 semantic-release 已经自动化了 npm 包的发布进程,但它需要关闭双因素认证或传入一个绕过此限制的秘密令牌。

🌐 While semantic-release already automates the npm package publishing process, it requires turning off two-factor authentication or passing in a secret token that bypasses this restriction.

我们构建了 CFA,用于为 npm 双因素认证 (2FA) 提供基于时间的一次性密码 (TOTP) 到任意 CI 作业,从而让我们能够利用 semantic-release 的自动化,同时保持双因素认证的额外安全性。

🌐 We built CFA to deliver a time-based one-time password (TOTP) for npm 2FA to arbitrary CI jobs, allowing us to harness the automation of semantic-release while keeping the additional security of two-factor authentication.

我们使用带有 Slack 集成前端的 CFA,使维护者可以从任何安装了 Slack 的设备上验证软件包发布,只要他们手边有 TOTP 生成器。

🌐 We use CFA with a Slack integration front-end, allowing maintainers to validate package publishing from any device they have Slack on, as long as they have their TOTP generator handy.

info

如果你想在自己的项目中尝试 CFA,可以查看 GitHub 仓库文档! 如果你使用 CircleCI 作为 CI 提供商,我们还有 一个方便的 orb 可以快速使用 CFA 搭建项目。

🌐 If you want to try CFA out in your own projects, check out the GitHub repository or the docs! If you use CircleCI as your CI provider, we also have a handy orb to quickly scaffold a project with CFA.

Sheriff

Sheriff 是我们编写的一个开源工具,用于自动管理 GitHub、Slack 和 Google Workspace 的权限。

Sheriff 的核心价值主张是权限管理应该是一个透明的进程。它使用一个单一的 YAML 配置文件来指定上述所有服务的权限。使用 Sheriff,获得仓库的协作者身份或创建一个新的邮件列表就像批准并合并一个 PR 一样简单。

🌐 Sheriff’s key value proposition is that permission management should be a transparent process. It uses a single YAML config file that designates permissions across all the above listed services. With Sheriff, getting collaborator status on a repo or creating a new mailing list is as easy as getting a PR approved and merged.

Sheriff 还有一个审计日志,会发布到 Slack,当 Electron 组织中的任何地方发生可疑活动时,会警告管理员。

🌐 Sheriff also has an audit log that posts to Slack, warning admins when suspicious activity occurs anywhere in the Electron organization.

……以及我们所有的 GitHub 机器人

🌐 …and all our GitHub bots

GitHub 是一个具有丰富 API 可扩展性的平台,并且拥有一个名为 Probot 的第一方机器人应用框架。为了帮助我们专注于工作中更具创造性的部分,我们开发了一系列小型机器人,帮助我们处理繁琐的工作。以下是几个示例:

🌐 GitHub is a platform with rich API extensibility and a first-party bot application framework called Probot. To help us focus on the more creative parts of our job, we built out a suite of smaller bots that help do the dirty work for us. Here are a few examples:

  • Sudowoodo 自动化了 Electron 的整个发布进程,从启动构建到将发布资源上传到 GitHub 和 npm,一应俱全。
  • Trop 通过尝试根据 GitHub PR 标签将补丁挑选到以前的发布分支,自动化 Electron 的回移植进程。
  • Roller 自动化 Electron 的 Chromium 和 Node.js 依赖的滚动升级。
  • Cation 是我们用于 electron/electron PR 的状态检查机器人。

总而言之,我们的机器人小家族极大地提高了开发者的生产力!

🌐 Altogether, our little family of bots has given us a huge boost in developer productivity!

下一步是什么?

🌐 What’s next?

随着我们作为一个项目进入第二个十年,你可能会问:Electron 的下一步是什么?

🌐 As we enter our second decade as a project, you might be asking: what’s next for Electron?

我们将与 Chromium 的发布节奏保持同步,每 8 周发布一次 Electron 的新主版本,使框架保持最新的 Web 平台和 Node.js 特性,同时确保企业级应用的稳定性和安全性。

🌐 We’re going to stay in sync with Chromium's release cadence, releasing new major versions of Electron every 8 weeks, keeping the framework updated with the latest and greatest from the web platform and Node.js while maintaining stability and security for enterprise-grade applications.

我们通常会在即将开展的计划变得具体时发布相关新闻。如果你想了解未来的版本、功能和一般项目更新,可以阅读我们的博客并关注我们的社交媒体账户(TwitterMastodon)!

🌐 We generally announce news on upcoming initiatives when they become concrete. If you want to keep up with future releases, features, and general project updates, you can read our blog and follow our social media profiles (Twitter and Mastodon)!

[^1]: 这实际上是来自 electron-archive/brightray 项目 的第一个提交,该项目在 2017 年被并入 Electron 并合并了其 git 历史记录。但谁在乎呢? 今天是我们的生日,所以我们可以自己定规则!

[^2]:与大众认知相反,Electron 目前不再由 GitHub 或微软拥有,而是如今属于 OpenJS 基金会 的一部分。

Electron 23.0.0

· 6 min read

Electron 23.0.0 已发布!它包括对 Chromium 110、V8 11.0 和 Node.js 18.12.1 的升级。此外,不再支持 Windows 7/8/8.1。请阅读以下内容了解更多详情!

🌐 Electron 23.0.0 has been released! It includes upgrades to Chromium 110, V8 11.0, and Node.js 18.12.1. Additionally, support for Windows 7/8/8.1 has been dropped. Read below for more details!


Electron 团队很高兴地宣布发布 Electron 23.0.0!你可以通过 npm 使用 npm install electron@latest 安装,或从我们的发布网站下载。请继续阅读以了解此次发布的详细信息。

🌐 The Electron team is excited to announce the release of Electron 23.0.0! You can install it with npm via npm install electron@latest or download it from our releases website. Continue reading for details about this release.

如果你有任何反馈,请通过 Twitter 与我们分享,或加入我们的社区 Discord!你可以在 Electron 的 问题追踪器 中报告错误和功能请求。

🌐 If you have any feedback, please share it with us on Twitter, or join our community Discord! Bugs and feature requests can be reported in Electron's issue tracker.

放弃对 Windows 7/8/8.1 的支持

🌐 Dropping Windows 7/8/8.1 Support

Electron 23 不再支持 Windows 7/8/8.1。Electron 遵循 Chromium 的计划弃用政策,该政策将在 Chromium 109 中弃用对 Windows 7/8/8.1 以及 Windows Server 2012 和 2012 R2 的支持(点击此处了解更多信息)(https://support.google.com/chrome/thread/185534985/sunsetting-support-for-windows-7-8-8-1-in-early-2023?hl=en)。

🌐 Electron 23 no longer supports Windows 7/8/8.1. Electron follows the planned Chromium deprecation policy, which will deprecate Windows 7/8/8.1 , as well as Windows Server 2012 and 2012 R2 support in Chromium 109 (read more here).

Electron 22.0.0

· 9 min read

Electron 22.0.0 已发布!它包含一个新的实用程序进程 API,对 Windows 7/8/8.1 的支持进行了更新,并升级了 Chromium 108、V8 10.8 和 Node.js 16.17.1。详见以下内容!

🌐 Electron 22.0.0 has been released! It includes a new utility process API, updates for Windows 7/8/8.1 support, and upgrades to Chromium 108, V8 10.8, and Node.js 16.17.1. Read below for more details!


Electron 团队很高兴地宣布发布 Electron 22.0.0!你可以通过 npm 使用 npm install electron@latest 安装,或从我们的发布网站下载。请继续阅读以了解此次发布的详细信息。

🌐 The Electron team is excited to announce the release of Electron 22.0.0! You can install it with npm via npm install electron@latest or download it from our releases website. Continue reading for details about this release.

如果你有任何反馈,请通过 Twitter 与我们分享,或加入我们的社区 Discord!你可以在 Electron 的 问题追踪器 中报告错误和功能请求。

🌐 If you have any feedback, please share it with us on Twitter, or join our community Discord! Bugs and feature requests can be reported in Electron's issue tracker.

Windows 7/8/8.1 支持更新

🌐 Windows 7/8/8.1 Support Update

info

2023/02/16:关于 Windows Server 2012 支持的更新

上个月,谷歌宣布Chrome 109将继续为Windows Server 2012和Windows Server 2012 R2提供关键安全修复,直到2023年10月10日。根据这一安排,Electron 22(Chromium 108)的计划终止支持日期将从2023年5月30日延长至2023年10月10日。Electron 团队将继续将该计划中的任何安全修复回移到 Electron 22,直至2023年10月10日。

🌐 Last month, Google announced that Chrome 109 would continue to receive critical security fixes for Windows Server 2012 and Windows Server 2012 R2 until October 10, 2023. In accordance, Electron 22's (Chromium 108) planned end of life date will be extended from May 30, 2023 to October 10, 2023. The Electron team will continue to backport any security fixes that are part of this program to Electron 22 until October 10, 2023.

请注意,我们将不会对 Windows 7/8/8.1 提供额外的安全修复。此外,正如之前所宣布的,Electron 23(Chromium 110)仅在 Windows 10 及以上版本上运行。

🌐 Note that we will not make additional security fixes for Windows 7/8/8.1. Also, Electron 23 (Chromium 110) will only function on Windows 10 and above as previously announced.

Electron 22 将是最后一个支持 Windows 7/8/8.1 的 Electron 主要版本。Electron 遵循 Chromium 的计划弃用政策,该政策将在 Chromium 109 中弃用对 Windows 7/8/8.1 的支持(在这里了解更多信息](https://support.google.com/chrome/thread/185534985/sunsetting-support-for-windows-7-8-8-1-in-early-2023?hl=en))。

🌐 Electron 22 will be the last Electron major version to support Windows 7/8/8.1. Electron follows the planned Chromium deprecation policy, which will deprecate Windows 7/8/8.1 support in Chromium 109 (read more here).

Electron 23 及更高主要版本将不支持 Windows 7/8/8.1。

🌐 Windows 7/8/8.1 will not be supported in Electron 23 and later major releases.

显著变化

🌐 Notable Changes

UtilityProcess API #36089

新的 UtilityProcess 主进程模块允许创建一个轻量级的 Chromium 子进程,该子进程仅集成了 Node.js,同时也允许使用 MessageChannel 与沙盒渲染器进行通信。该 API 基于 Node.js child_process.fork 设计,以便于更轻松的过渡,主要区别在于入口点 modulePath 必须来自打包后的应用内部,以确保只加载受信任的脚本。此外,该模块默认阻止与渲染器建立通信通道,从而维持主进程是应用中唯一受信任进程的约定。

🌐 The new UtilityProcess main process module allows the creation of a lightweight Chromium child process with only Node.js integration while also allowing communication with a sandboxed renderer using MessageChannel. The API was designed based on Node.js child_process.fork to allow for easier transition, with one primary difference being that the entry point modulePath must be from within the packaged application to allow only for trusted scripts to be loaded. Additionally the module prevents establishing communication channels with renderers by default, upholding the contract in which the main process is the only trusted process in the application.

你可以在我们的文档中阅读有关 新 UtilityProcess API 的更多信息

🌐 You can read more about the new UtilityProcess API in our docs here.

其他高亮的变更

🌐 Additional Highlighted Changes

  • 在 Linux 和 Windows 上新增了对 Web 蓝牙 PIN 配对的支持。 #35416
  • 添加了 LoadBrowserProcessSpecificV8Snapshot 作为一个新的开关,它将允许主进程/浏览器进程从 browser_v8_context_snapshot.bin 的文件加载其 v8 快照。其他进程将使用与当前相同的路径。 #35266
  • 添加了 WebContents.opener 用于访问窗口打开者,以及 webContents.fromFrame(frame) 用于获取与 WebFrameMain 实例对应的 WebContents。#35140
  • 通过新的会话处理器 ses.setDisplayMediaRequestHandler 添加了对 navigator.mediaDevices.getDisplayMedia 的支持。 #30702

告别 Windows 7/8/8.1

· 5 min read

Electron 将从 Electron 23 开始停止对 Windows 7、Windows 8 和 Windows 8.1 的支持。

🌐 Electron will end support of Windows 7, Windows 8 and Windows 8.1 beginning in Electron 23.


根据 Chromium 的废弃政策,Electron 将从 Electron 23 开始停止对 Windows 7、Windows 8 和 Windows 8.1 的支持。这与微软在 2023 年 1 月 10 日对 Windows 7 ESUWindows 8.1 扩展支持 结束支持的时间一致。

Electron 22 将是最后一个支持 Windows 10 之前版本的主要 Electron 版本。Windows 7/8/8.1 将不再在 Electron 23 及以后的主要版本中得到支持。旧版本的 Electron 将继续在 Windows 7 上运行,我们将继续为 Electron 22.x 系列发布修补程序,直到 2023 年 5 月 30 日,届时 Electron 将结束对 22.x 的支持(根据我们的支持时间表)。

🌐 Electron 22 will be the last Electron major version to support Windows versions older than 10. Windows 7/8/8.1 will not be supported in Electron 23 and later major releases. Older versions of Electron will continue to function on Windows 7, and we will continue to release patches for Electron the 22.x series until May 30 2023, when Electron will end support for 22.x (according to our support timeline).

为什么要弃用?

🌐 Why deprecate?

Electron 遵循计划中的 Chromium 弃用政策,该政策将在 Chromium 109 中弃用支持(在此阅读有关 Chromium 时间表的更多信息)。Electron 23 将包含 Chromium 110,它将不再支持较旧版本的 Windows。

🌐 Electron follows the planned Chromium deprecation policy, which will deprecate support in Chromium 109 (read more about Chromium's timeline here). Electron 23 will contain Chromium 110, which won’t support older versions of Windows.

因此,包含 Chromium 108 的 Electron 22 将成为最后一个受支持的版本。

🌐 Electron 22, which contains Chromium 108, will thus be the last supported version.

弃用时间表

🌐 Deprecation timeline

以下是我们计划的弃用时间表:

🌐 The following is our planned deprecation timeline:

  • 2022年12月:Electron 团队正在进入假期的平静期
  • 2023年1月:所有支持的发布分支均接受与 Windows 7 和 8 相关的问题。
  • 2023年2月7日:Electron 23 发布。
  • 2023年2月8日 - 2023年5月29日:Electron将继续接受对早于Electron 23的支持版本的修复。
  • 2023年5月30日:Electron 22 达到其支持周期的终点。

这对开发者意味着什么:

🌐 What this means for developers:

  • Electron 团队将接受与 Windows 7/8/8.1 相关的问题和修复,以支持稳定的产品线,直到每个产品线达到其支持周期的结束。
    • 这特别适用于 Electron 22、Electron 21 和 Electron 20。
  • 对于 Electron 23 之前的 Electron 版本,将接受与 Windows 7/8/8.1 相关的新问题。
    • 任何较新的发行版将不再接受新问题。
  • 一旦 Electron 22 达到其支持周期的结束,所有与 Windows 7/8/8.1 相关的现有问题都将被关闭。
info

2023/02/16:关于 Windows Server 2012 支持的更新

上个月,谷歌宣布Chrome 109将继续为Windows Server 2012和Windows Server 2012 R2提供关键安全修复,直到2023年10月10日。根据这一安排,Electron 22(Chromium 108)的计划终止支持日期将从2023年5月30日延长至2023年10月10日。Electron 团队将继续将该计划中的任何安全修复回移到 Electron 22,直至2023年10月10日。

🌐 Last month, Google announced that Chrome 109 would continue to receive critical security fixes for Windows Server 2012 and Windows Server 2012 R2 until October 10, 2023. In accordance, Electron 22's (Chromium 108) planned end of life date will be extended from May 30, 2023 to October 10, 2023. The Electron team will continue to backport any security fixes that are part of this program to Electron 22 until October 10, 2023.

请注意,我们将不会对 Windows 7/8/8.1 提供额外的安全修复。此外,正如之前所宣布的,Electron 23(Chromium 110)仅在 Windows 10 及以上版本上运行。

🌐 Note that we will not make additional security fixes for Windows 7/8/8.1. Also, Electron 23 (Chromium 110) will only function on Windows 10 and above as previously announced.

下一步是什么

🌐 What's next

如果你有任何问题或疑虑,请随时写信至 info@electronjs.org 联系我们。你也可以在我们的官方 Electron Discord 社区寻求支持。

🌐 Please feel free to write to us at info@electronjs.org if you have any questions or concerns. You can also find community support in our official Electron Discord.

寂静之地2(2022年12月)

· 2 min read

Electron 项目将在 2022 年 12 月暂停,然后在 2023 年 1 月恢复全速运行。

🌐 The Electron project will pause for the month of December 2022, then return to full speed in January 2023.

via GIPHY


12 月会有什么相同之处?

🌐 What will be the same in December

  1. 零日漏洞及其他主要的安全相关版本将在必要时发布。安全事件应通过 SECURITY.md 报告。
  2. 行为准则 的举报和管理将继续进行。

12 月会有什么不同?

🌐 What will be different in December

  1. 十二月没有新的稳定版本。十二月的最后两周没有夜间版和测试版发布。
  2. 除了少数例外,无需进行拉取请求审核或合并。
  3. 任何代码库均未更新问题跟踪器。
  4. 维护人员未提供 Discord 调试帮助。
  5. 无需更新社交媒体内容。

为什么会发生这种情况?

🌐 Why is this happening?

继2021年12月的安静月份活动成功之后,我们希望在2022年再次推出。对于大多数公司来说,12月仍然是一个比较安静的月份,所以我们希望给维护者们一个充电的机会。大家都在期待2023年,我们也期待美好的事情到来!我们鼓励其他项目考虑采取类似的措施。

🌐 With the success of December Quiet Month 2021, we wanted to bring it back for 2022. December continues to be a quiet month for most companies, so we want to give our maintainers a chance to recharge. Everyone is looking forward to 2023, and we expect good things to come! We encourage other projects to consider similar measures.

介绍 Electron Forge 6

· 11 min read

我们很高兴地宣布,Electron Forge v6.0.0 现已发布!此次发布是 Forge 自 2018 年以来的首次重大版本更新,并将项目从 electron-userland 转移到 Github 上的主要 electron 组织中。

🌐 We are excited to announce that Electron Forge v6.0.0 is now available! This release marks the first major release of Forge since 2018 and moves the project from electron-userland into the main electron organization on Github.

继续阅读,了解最新动态以及你的应用如何应用 Electron Forge!

🌐 Keep on reading to see what's new and how your app can adopt Electron Forge!

什么是 Electron Forge?

🌐 What is Electron Forge?

Electron Forge 是一个用于打包和分发 Electron 应用的工具。它将 Electron 的构建工具生态系统统一到一个可扩展的界面中,使任何人都可以直接开始制作 Electron 应用。

亮点功能包括:

🌐 Highlight features include:

  • 📦 应用打包与代码签名
  • 🚚 可在 Windows、macOS 和 Linux 上自定义安装程序(DMG、deb、MSI、PKG、AppX 等)
  • ☁️ 面向云提供商(GitHub、S3、Bitbucket 等)的自动发布进程
  • ⚡️ 易于使用的 webpack 和 TypeScript 模板
  • ⚙️ 原生 Node.js 模块支持
  • 🔌 可扩展的 JavaScript 插件 API
进一步阅读

访问 Why Electron Forge 解释文档,了解更多关于 Forge 的理念和架构。

🌐 Visit the Why Electron Forge explainer document to learn more about Forge's philosophy and architecture.

v6 有什么新功能?

🌐 What's new in v6?

完全重写

🌐 Completely rewritten

从 v1 到 v5,Electron Forge 基于现已停止维护的 electron-compile 项目。Forge 6 是对该项目的全面重写,采用了新的模块化架构,可以扩展以满足任何 Electron 应用的需求。

🌐 From v1 to v5, Electron Forge was based on the now-discontinued electron-compile project. Forge 6 is a complete rewrite of the project with a new modular architecture that can be extended to meet any Electron application's needs.

在过去几年里,Forge v6.0.0-beta 已经实现了与 v5 的功能等同,并且代码更迭明显减缓,使该工具准备好被广泛采用。

🌐 In the past few years, Forge v6.0.0-beta has achieved feature parity with v5 and code churn has slowed down dramatically, making the tool ready for general adoption.

不要安装错误的软件包

对于 5 及以下版本,Electron Forge 发布在 npm 的 electron-forge 包上。从 v6 重写开始,Forge 改为以单仓库项目的形式组织,包含许多较小的子项目。

🌐 For versions 5 and below, Electron Forge was published to the electron-forge package on npm. Starting with the v6 rewrite, Forge is instead structured as a monorepo project with many smaller projects.

官方支持

🌐 Officially supported

从历史上看,Electron 的维护者对构建工具持无偏见态度,将这项任务交给各种社区包。然而,随着 Electron 项目的成熟,新入门的 Electron 开发者越来越难以理解他们需要哪些工具来构建和分发应用。

🌐 Historically, Electron maintainers have been unopinionated about build tooling, leaving the task to various community packages. However, with Electron maturing as a project, it has become harder for new Electron developers to understand which tools they need to build and distribute their apps.

为了帮助指导 Electron 开发者进行分发进程,我们决定将 Forge 定为 Electron 的官方全功能构建管道

🌐 To help guide Electron developers in the distribution process, we have have decided to make Forge the official batteries-included build pipeline for Electron.

在过去的一年里,我们一直在将 Forge 慢慢整合到官方的 Electron 文档中,最近我们已将 Forge 从它旧的存放位置 electron-userland/electron-forge 移动到了 electron/forge 仓库。现在,我们终于准备好向大众发布 Electron Forge 了!

🌐 Over the past year, we have been slowly integrating Forge into the official Electron documentation, and we have recently moved Forge over from its old home in electron-userland/electron-forge to the electron/forge repo. Now, we are finally ready to release Electron Forge to a general audience!

入门

🌐 Getting started

初始化新的 Forge 项目

🌐 Initializing a new Forge project

可以使用 create-electron-app CLI 脚本来搭建一个新的 Electron Forge 项目。

🌐 Scaffolding a new Electron Forge project can be done using the create-electron-app CLI script.

yarn create electron-app my-app --template=webpack
cd my-app
yarn start

该脚本将在 my-app 文件夹中创建一个 Electron 项目,采用完全的 JavaScript 打包并预配置构建流水线。

🌐 The script will create an Electron project in the my-app folder with completely JavaScript bundling and a preconfigured build pipeline.

欲了解更多信息,请参阅 Forge 文档中的《入门指南》。

🌐 For more info, see the Getting Started guide in the Forge docs.

一流的 Webpack 支持

上面的代码片段使用了 Forge 的 [Webpack 模板],我们推荐将其作为新 Electron 项目的起点。该模板基于 @electron-forge/plugin-webpack 插件构建,该插件以几种方式将 webpack 与 Electron Forge 集成,包括:

🌐 The above snippet uses Forge's Webpack Template, which we recommend as a starting point for new Electron projects. This template is built around the @electron-forge/plugin-webpack plugin, which integrates webpack with Electron Forge in a few ways, including:

  • 通过 webpack-dev-server 提升本地开发进程,包括对渲染器中 HMR 的支持;
  • 在应用打包之前处理 webpack 包的构建逻辑;以及
  • 在 Webpack 打包进程中添加对原生 Node 模块的支持。

如果你需要 TypeScript 支持,可以考虑使用 [Webpack + TypeScript 模板]。

🌐 If you need TypeScript support, consider using the Webpack + TypeScript Template instead.

导入现有项目

🌐 Importing an existing project

Electron Forge CLI 还包含用于导入现有 Electron 项目的命令。

🌐 The Electron Forge CLI also contains an import command for existing Electron projects.

cd my-app
yarn add --dev @electron-forge/cli
yarn electron-forge import

当你使用 import 命令时,Electron Forge 会添加一些核心依赖并创建一个新的 forge.config.js 配置。如果你已经有任何现有的构建工具(例如 Electron Packager、Electron Builder 或 Forge 5),它将尝试迁移尽可能多的设置。你的一些现有配置可能需要手动迁移。

🌐 When you use the import command, Electron Forge will add a few core dependencies and create a new forge.config.js configuration. If you have any existing build tooling (e.g. Electron Packager, Electron Builder, or Forge 5), it will try to migrate as many settings as possible. Some of your existing configuration may need to be migrated manually.

手动迁移的详细信息可以在 Forge 的 [导入文档] 中找到。如果你需要帮助,请访问 我们的 Discord 服务器

🌐 Manual migration details can be found in the Forge import documentation. If you need help, please stop by our Discord server!

为什么要切换到 Forge?

🌐 Why switch to Forge?

如果你已经拥有用于打包和发布 Electron 应用的工具,那么采用 Electron Forge 带来的好处仍然可以超过最初的切换成本。

🌐 If you already have tooling for packaging and publishing your Electron app, the benefits associated with adopting Electron Forge can still outweigh the initial switching cost.

我们认为使用 Forge 有两个主要好处:

🌐 We believe there are two main benefits to using Forge:

  1. Forge 会在 Electron 支持新功能时立即获得新的应用构建特性。在这种情况下,你不需要自己接入新的工具支持,也不必等待其他包最终实现该支持后再升级。最近的案例包括 macOS 通用二进制ASAR 完整性检查
  2. Forge 的多包架构使其易于理解和扩展。 由于 Forge 由许多具有明确职责的小包组成,因此代码进程更容易理解。此外,Forge 可扩展的 API 设计意味着你可以为高级用例编写自己的附加构建逻辑,而不依赖提供的配置选项。有关编写自定义 Forge 插件、制造器和发布器的更多详细信息,请参阅文档中的 [扩展 Electron Forge] 部分。

重大变更

🌐 Breaking changes

Forge 6 在测试阶段已经花费了很长时间,其发布节奏逐渐放缓。然而,我们在 2022 年下半年加快了开发,并利用最近几次发布推进了一些最终的重大变更,为 v6.0.0 稳定版做准备。

🌐 Forge 6 has spent a long time in the beta phase, and its release cadence has gradually slowed down. However, we have accelerated development in the second half of 2022 and used the last few releases to push some final breaking changes before the v6.0.0 stable release.

如果你是 Electron Forge 6 测试版用户,请查看 v6.0.0 GitHub 发行说明 以获取最近测试版 (>=6.0.0-beta.65) 中重大更改的列表。

🌐 If you are an Electron Forge 6 beta user, see the v6.0.0 GitHub release notes for a list of breaking changes made in recent betas (>=6.0.0-beta.65).

完整的更改和提交列表可以在仓库的 CHANGELOG.md 中找到。

🌐 A complete list of changes and commits can be found in the repo's CHANGELOG.md.

提交你的反馈!

🌐 Submit your feedback!

告诉我们你的需求!Electron Forge 团队一直在努力打造更适合用户的项目。

🌐 Tell us what you need! The Electron Forge team is always looking to build the project to better suit its users.

你可以通过提交功能请求、发布问题或仅仅提供反馈来帮助我们改进 Electron Forge!你还可以加入我们的官方 Electron Discord 服务器,那里有专门的通道用于 Electron Forge 讨论。

🌐 You can help us improve Electron Forge by submitting feature requests, posting issues, or just letting us know your feedback! You can also join us in the official Electron Discord server, where there is a dedicated channel for Electron Forge discussion.

如果你想对 https://electronforge.io 上的 Forge 文档提供任何反馈,我们有一个 GitBook 实例,它与 electron-forge/electron-forge-docs 仓库同步。

🌐 If you want to give any feedback on the Forge docs at https://electronforge.io, we have a GitBook instance synced to the electron-forge/electron-forge-docs repo.

维护者峰会2022回顾

· 10 min read

🌐 Maintainer Summit 2022 Recap

上个月,Electron 的维护者团队在加拿大温哥华聚会,讨论了 2023 年及以后的项目发展方向。在为期四天的会议室讨论中,核心维护者和受邀的合作者讨论了新的计划、维护中的痛点以及项目的整体健康状况。

🌐 Last month, Electron’s maintainer group met up in Vancouver, Canada to discuss the direction of the project for 2023 and beyond. Over four days in a conference room, core maintainers and invited collaborators discussed new initiatives, maintenance pain points, and general project health.

合影!由 @groundwater拍摄。

今后,团队仍将全力致力于发布定期且快速的 Chromium 升级,修复漏洞,并让 Electron 对所有人来说更安全、更高效。我们也有一些令人兴奋的项目正在进行中,期待与社区分享!

🌐 Going forward, the team will still be fully dedicated to releasing regular and rapid Chromium upgrades, fixing bugs, and making Electron more secure and performant for everyone. We also have a few exciting projects in the works we would love to share with the community!

变革性的新 API

🌐 Transformative new APIs

Electron 项目中需要达成共识的主要 API 提案会经过征求意见稿(RFC)进程,由我们的 API 工作组成员进行审查。

🌐 Major API proposals in the Electron project that require consensus go through a Request for Comments (RFC) process, which gets reviewed by members of our API Working Group.

今年,我们推动了两项具有潜力为 Electron 应用解锁新功能维度的重大提案。这些提案仍处于高度实验阶段,但这里给大家抢先看一下未来的可能!

🌐 This year, we have driven forward two major proposals that have the potential to unlock a new dimension of capabilities for Electron apps. These proposals are highly experimental, but here’s a sneak peek of what to expect!

新的原生插件增强功能 (C API)

🌐 New native addon enhancements (C APIs)

本提案概述了一个新的 Electron C API 层,它将允许应用开发者编写自己的本地 Node 插件,以接口与 Electron 的内部资源,类似于 Node 自身的 Node-API。关于拟议的新 API 的更多信息可以在这里找到。

🌐 This proposal outlines a new layer of Electron C APIs that will allow app developers to write their own Native Node Addons that interface with Electron’s internal resources, similar to Node’s own Node-API. More information about the proposed new API can be found here.

示例:使用 Chromium 资源强化应用

🌐 Example: Supercharging apps with Chromium resources

许多 Electron 应用维护自己的分支,以直接与 Chromium 内部交互,这些内部在普通(未修改的)Electron 中是无法访问的。通过在 C API 层暴露这些资源,这段代码可以作为一个原生模块与 Electron 一起运行,从而可能减少应用开发者的维护负担。

🌐 Many Electron apps maintain their own forks to interact directly with Chromium internals that would otherwise be inaccessible with vanilla (unmodified) Electron. By exposing these resources in the C API layer, this code can instead live as a native module alongside Electron, potentially reducing app developer maintenance burden.

公开 Chromium 的 UI 层(Views API)

🌐 Exposing Chromium’s UI layer (Views API)

在底层,Chrome 的用户界面(UI)中非网站部分,如工具栏、标签或按钮,是使用一种名为 Views 的框架构建的。Views API 提案将该框架的部分内容作为 JavaScript 类引入 Electron,最终目标是允许开发者为他们的 Electron 应用创建非网页 UI 元素。这将避免应用不得不拼凑网页内容。

🌐 Under the hood, the non-website parts of Chrome’s user interface (UI), such as toolbars, tabs, or buttons, are built with a framework called Views. The Views API proposal introduces parts of this framework as JavaScript classes in Electron, with the eventual goal of allowing developers to create non-web UI elements to their Electron applications. This will prevent apps from having to hack together web contents.

使这一新套API成为可能的基础工作目前正在进行中。以下是你在不久的将来可以期待的一些首批功能。

🌐 The groundwork to make this new set of APIs possible is currently in progress. Here are a few of the first things you can expect in the near future.

示例:使用 WebContentsView 重构窗口模型

🌐 Example: Refactoring the window model with WebContentsView

我们计划的第一个变更是将 Chrome 的 WebContentsView 暴露给 Electron 的 API 接口,它将成为我们现有 BrowserView API 的继任者(尽管名称如此,但 BrowserView 是 Electron 特有的代码,与 Chromium Views 无关)。通过暴露 WebContentsView,我们将拥有一个可重用的 View 对象来显示网页内容,这为将 BrowserWindow 类完全转为 JavaScript 并进一步减少代码复杂性打开了大门。

🌐 Our first planned change is to expose Chrome’s WebContentsView to Electron’s API surface, which will be the successor to our existing BrowserView API (which, despite the name, is Electron-specific code unrelated to Chromium Views). With WebContentsView exposed, we will have a reusable View object that can display web contents, opening the door to making the BrowserWindow class pure JavaScript and eliminating even more code complexity.

虽然这一变化并没有为应用开发者提供大量新的功能,但它是一次大规模重构,消除了大量底层代码,简化了 Chromium 的升级,并减少了在主要版本之间出现新错误的风险。

🌐 Although this change doesn’t provide a lot of new functionality to app developers, it is a large refactor that eliminates a lot of code under the hood, simplifying Chromium upgrades and reducing the risk of new bugs appearing between major versions.

如果你是一个在应用中使用 BrowserViews 的 Electron 开发者:别担心,我们没有忘记你!我们计划将现有的 BrowserView 类作为 WebContentsView 的一个兼容层,以在你过渡到更新的 API 时提供缓冲。

🌐 If you’re an Electron developer using BrowserViews in your app: don’t worry, we haven’t forgotten about you! We plan on making the existing BrowserView class a shim for WebContentsView to provide a buffer as you transition to the newer APIs.

参见:electron/electron#35658

🌐 See: electron/electron#35658

示例:带有 ScrollView 的可滚动网页内容

🌐 Example: Scrollable web contents with ScrollView

我们在 Stack 的朋友一直在推动一项计划,将 Chromium 的 ScrollView 组件暴露给 Electron 的 API。通过这个新 API,任何子 View 组件都可以设置为水平或垂直滚动。

🌐 Our friends at Stack have been driving an initiative to expose the Chromium ScrollView component to Electron’s API. With this new API, any child View component can be made scrollable horizontally or vertically.

虽然这个新的 API 仅实现了一个较小的功能,但团队最终的目标是构建一套实用的视图组件,这些组件可以作为工具包用于构建更复杂的非 HTML 界面。

🌐 Although this new API fulfills a single smaller functionality, the team’s eventual goal is to build a set of utility View components that can be used as a toolkit to build more complex non-HTML interfaces.

参与其中

🌐 Getting involved

你是一名对这些 API 提案感兴趣的 Electron 应用开发者吗?虽然我们还没有准备好接收更多的 RFC,请继续关注未来的更多细节!

🌐 Are you an Electron app developer interested in either of these API proposals? Although we’re not quite ready to receive additional RFCs, please stay tuned for more details in the future!

Electron Forge v6 稳定版

🌐 Electron Forge v6 stable release

自从该框架诞生以来,Electron 的构建工具生态系统主要由社区驱动,由许多小型、单一功能的包组成(例如 electron-winstaller、electron-packager、electron-notarize、electron-osx-sign)。虽然这些工具运作良好,但对于用户来说,要拼凑出一个可用的构建进程仍然令人望而生畏。

🌐 Since the framework’s inception, Electron’s build tooling ecosystem has been largely community-driven and has consisted of many small single-purpose packages (e.g. electron-winstaller, electron-packager, electron-notarize, electron-osx-sign). Although these tools work well, it’s intimidating for users to piece together a working build pipeline.

为了帮助为 Electron 开发者打造一个更友好的体验,我们创建了 Electron Forge,这是一种一体化解决方案,将所有现有的工具整合到一个界面中。虽然 Forge 自 2017 年起就开始开发,但在过去几年中该项目一直处于休眠状态。然而,鉴于社区对 Electron 构建工具现状的反馈,我们一直在努力发布下一代稳定的 Forge 主要版本。

🌐 To help build a friendlier experience for Electron developers, we built Electron Forge, an all-in-one solution that combines all this existing tooling into a single interface. Although Forge has been in development since 2017, the project has lain dormant for the last few years. However, given community feedback on the state of build tooling in Electron, we have been hard at work on releasing the next-gen stable major version of Forge.

Electron Forge 6 提供一流的 TypeScript 和 Webpack 支持,同时还具有可扩展的 API,允许开发者创建自己的插件和安装程序。

🌐 Electron Forge 6 comes with first-class TypeScript and Webpack support, as well as an extensible API that allows developers to create their own plugins and installers.

敬请关注:公告即将发布

🌐 Stay tuned: announcement coming soon

如果你有兴趣使用 Forge 构建项目,或者使用 Forge 可扩展的第三方 API 构建模板或插件,请继续关注我们关于 Forge v6 稳定版本的官方公告,预计将在本月发布!

🌐 If you’re interested in building a project with Forge or building templates or plugins with Forge’s extensible third-party APIs, stay tuned for our official announcement on the Forge v6 stable release sometime this month!

下一步是什么?

🌐 What’s next?

除了上述内容之外,团队还一直在考虑一系列探索性项目,以改善 Electron 给应用开发者和终端用户的体验。我们也在尝试更新工具、API 审查进程以及增强文档等其他方面的改进。我们希望在不久的将来能分享更多消息!

🌐 Aside from the above, the team is always thinking of a bunch of exploratory projects to make the Electron experience better for app developers and end users. Updater tooling, API review processes, and enhanced documentation are other things we are experimenting with. We hope to have more news to share in the near future!

Electron 21.0.0

· 5 min read

Electron 21.0.0 已经发布!它包括对 Chromium 106、V8 10.6 和 Node.js 16.16.0 的升级。请往下阅读获取更多详细信息!

🌐 Electron 21.0.0 has been released! It includes upgrades to Chromium 106, V8 10.6, and Node.js 16.16.0. Read below for more details!


Electron 团队很高兴地宣布发布 Electron 21.0.0!你可以通过 npm 使用 npm install electron@latest 安装,或从我们的发布网站下载。请继续阅读以了解此次发布的详细信息。

🌐 The Electron team is excited to announce the release of Electron 21.0.0! You can install it with npm via npm install electron@latest or download it from our releases website. Continue reading for details about this release.

如果你有任何反馈,请通过 Twitter 与我们分享,或加入我们的社区 Discord!你可以在 Electron 的 问题追踪器 中报告错误和功能请求。

🌐 If you have any feedback, please share it with us on Twitter, or join our community Discord! Bugs and feature requests can be reported in Electron's issue tracker.