Saltar al contenido principal

Resumen del ecosistema 2023

· 6 lectura mínima

Reflexionando sobre las mejoras y cambios en el ecosistema para desarrolladores de Electron en 2023.

¡En los últimos meses, hemos estado cocinando algunos cambios en el ecosistema de Electron para sobrecargar la experiencia de desarrollador para aplicaciones de Electron! Aquí hay un breve resumen de las últimas adiciones directamente de Electron HQ.

Electron Forge 7 y más allá

Electron Forge 7 — la versión más reciente de nuestra herramienta todo en uno para empacar y distribuir aplicaciones de Electron — ya está disponible.

Mientras Forge 6 fue una reescritura completa de v5, v7 es más pequeña en alcance, pero aún contiene algunos cambios de ruptura. Siguiendo adelante, continuaremos publicando versiones importantes de Forge a medida que se necesite realizar cambios relevantes.

Para más detalles, vea el listado completo de cambios de Forge v7.0.0 en GitHub.

Cambios notables

  • Se ha cambiado a notarytool para la notarización de macOS: En 2023-11-01, Apple puso fin a la altool heredada para la notarización de macOS y este lanzamiento la elimina de Electron Forge completamente.
  • Versión mínima de Node.js aumentada a v16.4.0: Con este lanzamiento, hemos establecido la versión mínima requerida de Node.js a 16.4.0.
  • Se ha eliminado el soporte para electron-prebuilt y electron-prebuilt-compile: electron-prebuilt era el nombre original para el módulo npm de Electron, pero se ha reemplazado por electron en v1.3.1. electron-prebuilt-console era una alternativa a ese binario que viene con características DX mejoradas, pero eventualmente fue abandonado como proyecto.


  • Editor de Google Cloud Storage: ¡Como parte de nuestro compromiso de mejorar el soporte de la actualización automática estática, Electron Forge ahora soporta la publicación directa a Google Cloud Storage!
  • Soporte para ESM forge.config.js: Electron Forge ahora soporta los archivos forge.config.js. (P.D. Look forward to ESM entrypoint support in Electron 28.)
  • Makers now run in parallel: In Electron Forge 6, Makers ran sequentially for ✨ legacy ✨ reasons. Since then, we’ve tested out parallelization for the Make step with no adverse side effects, so you should see a speed-up when building multiple targets for the same platform!
Thank you!

🙇 Big thanks to mahnunchik for the contributions for both the GCS Publisher and ESM support in Forge configurations!

Mejor soporte estático y actualizaciones automáticas

Squirrel.Windows and Squirrel.Mac are platform-specific updater technologies that back Electron’s built-in autoUpdater module. Both projects support auto updates via two methods:

  • A Squirrel-compatible update server
  • A manifest URL hosted on a static storage provider (e.g. AWS, Google Cloud Platform, Microsoft Azure, etc.)

The update server method has traditionally been the recommended approach for Electron apps (and provides additional customization of update logic), but it has a major downside—it requires apps to maintain their own server instance if they are closed-source.

On the other hand, the static storage method has always been possible, but was undocumented within Electron and poorly supported across Electron tooling packages.

With some great work from @MarshallOfSound, the update story for serverless automatic app updates has been drastically streamlined:

  • Electron Forge’s Zip and Squirrel.Windows makers can now be configured to output autoUpdater-compatible update manifests.
  • A new major version of update-electron-app (v2.0.0) can now read these generated manifests as an alternative to the server.

Once your Makers and Publishers are configured to upload update manifests to cloud file storage, you can enable auto updates with only a few lines of configuration:

const { updateElectronApp, UpdateSourceType } = require('update-electron-app');

updateSource: {
type: UpdateSourceType.StaticStorage,
baseUrl: `https://my-manifest.url/${process.platform}/${process.arch}`,
Leer más

📦 Want to learn more? For a detailed guide, see Forge’s auto update documentation.

The @electron/ extended universe

When Electron first started, the community published many packages to enhance the experience of developing, packaging, and distributing Electron apps. Over time, many of these packages were incorporated into Electron’s GitHub organization, with the core team taking on the maintenance burden.

In 2022, we began unifying all these first-party tools under the @electron/ namespace on npm. This change means that packages that used to be electron-foo are now @electron/foo on npm, and repositories that used to be named electron/electron-foo are now electron/foo on GitHub. These changes help clearly delineate first-party projects from userland projects. This includes many commonly used packages, such as:

  • @electron/asar
  • @electron/fuses
  • @electron/get
  • @electron/notarize
  • @electron/osx-sign
  • @electron/packager
  • @electron/rebuild
  • @electron/remote
  • @electron/symbolicate-mac
  • @electron/universal

Going forward, all first-party packages we release will also be in the @electron/ namespace. There are two exceptions to this rule:

  • Electron core will continue to be published under the electron package.
  • Electron Forge will continue to publish all of its monorepo packages under the @electron-forge/ namespace.
Star seeking

⭐ During this process, we also accidentally took the electron/packager repository private, which has the unfortunate side effect of erasing our GitHub star count (over 9000 before the erasure). If you are an active user of Packager, we’d appreciate a ⭐ Star ⭐!

Introducing @electron/windows-sign

Starting on 2023-06-01, industry standards began requiring keys for Windows code signing certificates to be stored on FIPS-compliant hardware.

In practice, this meant that code signing became a lot harder for apps that build and sign in CI environments, since many Electron tools take in a certificate file and password as config parameters and attempt to sign from there using hardcoded logic.

This situation has been a common pain point for Electron developers, which is why we have been working on a better solution that isolates Windows code signing into its own standalone step, similar to what @electron/osx-sign does on macOS.

In the future, we plan on fully integrating this package into the Electron Forge toolchain, but it currently lives on its own. The package is currently available for installation at npm install --save-dev @electron/windows-sign and can used programmatically or via CLI.

Please try it out and give us your feedback in the repo’s issue tracker!

What's next?

We'll be entering our annual December quiet period next month. While we do, we'll be thinking about how we can make the Electron development experience even better in 2024.

Is there anything you'd like to see us work on next? Haznos saber!