Electron v42.0.0-alpha.1

Latest Pre Release
npm
npm install --save-dev electron@42.0.0-alpha.1
yarn
yarn add --dev electron@42.0.0-alpha.1
Google ChromeChromium
147.0.7727.0
Node.jsNode.js
24.14.0
V8V8
14.7.173

Release Notes

Features

  • Added Notification.handleActivation(callback) API on Windows to handle notification clicks, replies, and action buttons - including when the app is launched from a notification (cold start). #49919

  • Added ELECTRON_INSTALL_PLATFORM and ELECTRON_INSTALL_ARCH variables to install binaries from other platforms and architectures. #49981

  • Added app.isActive() to check if the app is the active/foreground application (macOS only). #49622

  • Added webContents.getOrCreateDevToolsTargetId(). #49733 (Also in 41)

  • Added a disclaim option to the UtilityProcess API to allow for TCC disclaiming on macOS. #49128 (Also in 39, 40, 41)

  • Added a reason property to the Notification 'closed' event on Windows to allow developers to know the reason the Notification was dismissed. #49913 (Also in 40, 41)

  • Added an usePrinterDefaultPageSize option to webContents.print() to allow using the printer's default page size. #49523 (Also in 41)

  • Added animation functionality to view.setBounds and add view.setBackgroundBlur. #48812

  • Added support for MSIX auto-updating. #49230 (Also in 39, 40, 41)

  • Added support for --experimental-transform-types. #49711 (Also in 39, 40, 41)

  • Added support for long-animation-frame script attribution (via --enable-features=AlwaysLogLOAFURL). #49706 (Also in 39, 40, 41)

  • Added support for importing shared textures using the p010le 10-bit YUV pixel format. #49272

  • Added support for several more safeStorage backends via new asynchronous functionality in safeStorage. #49054

  • Added the ability to disable auto-focusing of WebContents on navigation using webPreferences.focusOnNavigation. #49425 (Also in 40, 41)

  • Changed offscreen scale factor use 1.0f as default. #49683

  • Electron now downloads its binary into node_modules dynamically on first launch instead of running a postinstall script. Added the install-electron script to manually trigger the download as well. #49328

  • Enable wasm trap handlers behind WasmTrapHandlers fuse. #48983 (Also in 41)

  • Extended actions support for Windows notifications to include buttons, select dropdowns, and replies. #48132 (Also in 40, 41)

  • On Wayland (Linux), frameless windows now have GTK drop shadows and extended resize boundaries. To create fully frameless windows with no decorations, set hasShadow: false in the window constructor. #49295 (Also in 41)

  • Replaced deprecated NSUserNotification with User Notifications. #47817

Fixes

  • Added validation to protocol client methods to reject protocol names that do not conform to the RFC 3986 URI scheme grammar. #50141 (Also in 38, 39, 40, 41)

  • Addressed upstream Chromium shift to enable CoreAudio Tap API for audio capture used in electron's desktopCapturer (🍏 macOS). #49717 (Also in 39, 40, 41)

  • Allow dynamically updating menu item labels, sublabels, and icons. #49678 (Also in 40, 41)

  • Fixed globalShortcut not working on Wayland with GlobalShortcutsPortal feature enabled. #49842 (Also in 40, 41)

  • Fixed a bug that cause offscreen rendering doesn't have valid screen info and unable to get valid result of related media queries.

    • Added webPreference.offscreen.deviceScaleFactor to allow user specify a value, instead of using user's primary display's value. #48730 (Also in 40)

  • Fixed a crash that could occur when using the File System Access API. #49578 (Also in 39, 40, 41)

  • Fixed a macOS crash when creating a new tab from the tab overview. #49917 (Also in 40, 41)

  • Fixed an application crash on MacOS where the menu observer was not being properly removed before garbage collection. #49648 (Also in 40, 41)

  • Fixed an error with Windows release builds after MSIX merger. #49613

  • Fixed an issue in chrome://accessibility. #49547 (Also in 39, 40, 41)

  • Fixed an issue on macOS where Universal Links were not delivered to app.on('continue-activity') on cold launch when NSUserActivity.userInfo was nil. #49986 (Also in 39, 40, 41)

  • Fixed an issue on macOS where calling autoUpdater.quitAndInstall() could fail if checkForUpdates() was called again after an update was already downloaded. #50210 (Also in 39, 40, 41)

  • Fixed an issue that caused the RGBAF16 shared texture format to have a keyed mutex on Windows. #49798 (Also in 41)

  • Fixed an issue where Chrome Devtools menus may not appear in certain embedded windows. #49794 (Also in 39, 40, 41)

  • Fixed an issue where VideoFrame objects returned through contextBridge had an incorrect prototype. #49997 (Also in 39, 40, 41)

  • Fixed an issue where additionalData passed to app.requestSingleInstanceLock on Windows could be truncated or fail to deserialize in the primary instance's second-instance event. #50119 (Also in 38, 39, 40, 41)

  • Fixed an issue where net.fetch() requests in the main process and utility processes would permanently fail with net::ERR_FAILED after the Network Service process crashed and restarted. #49887

  • Fixed an issue where nodeIntegrationInWorker overrides in setWindowOpenHandler were not honored for child windows sharing a renderer process with their opener. #50122 (Also in 38, 41)

  • Fixed an issue where screen.getCursorScreenPoint() crashed on Wayland when it was called before a BrowserWindow had been created. #50092 (Also in 39, 40, 41)

  • Fixed an issue where shell.writeShortcutLink was throwing TypeError: Insufficient number of arguments when called with just [(path, options)]. #49476 (Also in 39, 40, 41)

  • Fixed an issue where alt+space triggered th system context menu even if an accelerator was registered for the hotkey combination. #49619 (Also in 39, 40, 41)

  • Fixed an issue where calling setBounds on a WebContentsView could trigger redundant page-favicon-updated events even when the favicon had not changed. #49464 (Also in 39, 40, 41)

  • Fixed an issue where cookie changed events weren't properly emitted in all cases. #49103 (Also in 41)

  • Fixed an issue where frameless windows had resize issues in Mac App Store builds. #49780 (Also in 39, 40, 41)

  • Fixed an issue where invalid characters in custom protocol or webRequest response header values were not rejected. #50123 (Also in 38, 39, 40, 41)

  • Fixed an issue where making a window fullscreen on Windows, minimizing it and then restoring it broke previous fullscreen state. #49872 (Also in 40, 41)

  • Fixed an issue where malformed custom toastXml could cause a Notification crash. #49947 (Also in 40, 41)

  • Fixed an issue where menu item accelerators stopped working after the item's enabled property was toggled on macOS. #49553 (Also in 39, 40, 41)

  • Fixed an issue where menu item enabled state wasn't updated during key equivalent dispatch when the menu was closed on macOS. #49875 (Also in 39, 40, 41)

  • Fixed an issue where native modules would either crash or not compile for MacOS 12. #49697 (Also in 40, 41)

  • Fixed an issue where permission and device-chooser handlers received the top-level page origin instead of the requesting subframe's origin. #50052 (Also in 38, 39, 40, 41)

  • Fixed an issue where role-based menu items were incorrectly returning null for their accelerator property. #49558 (Also in 39, 40, 41)

  • Fixed an issue where setting zoomFactor in setWindowOpenHandler's overrideBrowserWindowOptions had no effect on windows opened via window.open(). #49886 (Also in 39, 40, 41)

  • Fixed an issue where some shell functionality may not work on Linux if the target window is already open. #49499 (Also in 41)

  • Fixed an issue where traffic light buttons would flash at position (0,0) when restoring a window with a custom trafficLightPosition from minimization on macOS. #50183 (Also in 39, 40, 41)

  • Fixed an issue whereby a duplicate "Toggle Full Screen" menu item appeared in the View menu on macOS. #49074 (Also in 38, 39, 40, 41)

  • Fixed bug where opening a message box immediately upon closing a child window may cause the parent window to freeze on Windows. #50078 (Also in 39, 40, 41)

  • Fixed build failure when printing is disabled. #50056 (Also in 41)

  • Fixed crash in platform_util::Beep() on Linux. #49442 (Also in 39, 40, 41)

  • Fixed dependency issue that caused Squirrel.Mac updates to fail. #49980

  • Fixed dock menu items not respecting enabled and checked properties on macOS. #49574 (Also in 38, 39, 40, 41)

  • Fixed draggable regions not updating position when DevTools is docked to the left or right in a frameless window. #49822 (Also in 39, 40, 41)

  • Fixed memory leak when setting icons on Linux/GTK. #49863 (Also in 38, 39, 40, 41)

  • Fixed menu bar hiding after a call to win.setFullScreen(false) when not in fullscreen on Linux. #45930 (Also in 39, 40, 41)

  • Fixed menus to correctly emit menu-will-close event when closed after any submenu has been open. #49783 (Also in 40, 41)

  • Fixed rendering glitches on macOS. #49608 (Also in 40, 41)

  • Fixed several issues with consistent window sizing and resizing on Linux when CSD is in use (e.g. on GNOME/Wayland) and added support for creating content-sized windows. #49209 (Also in 41)

  • Fixed shutdown crash on windows when hidden titlebar is enabled. #50042 (Also in 39, 40, 41)

  • Fixed startup crash when V8 sandbox is disabled. #49210 (Also in 40, 41)

  • Fixed webRequest handlers not being called for intercepted protocols and special net.fetch URLs. #45915

  • Fixed window sizing on Linux when min/max size constraints are set or resizable is false. Windows no longer shrink below the requested max size or grow taller when resizability is disabled. #49903 (Also in 41)

  • Global shortcuts can now be registered more reliably on Wayland using the globalShortcut API. #49988 (Also in 41)

  • Improved the appearance of shadows and borders on frameless windows on Wayland. #50007

Other Changes

  • Backported fix for 483569511. #49788

  • Fixed crash in platform_util::Beep() on Linux. #49680 (Also in 40, 41)

  • Refactored our MSIX updater code to use an upstream Chromium pattern and eliminates the need for special exception handling build flags. #49645 (Also in 39, 40, 41)

  • Updated Chromium to 147.0.7727.0. #50115

  • Updated Node.js to v24.14.0. #49941

Documentation

Unknown

  • Fixed CSS selector syntax in default app styles to properly apply animations to hero icons. #49950 (Also in 41)

  • Fixed an issue where some packages weren't correctly filtered on macOS in dialogs. #49444 (Also in 38, 39, 40, 41)

  • Fixed squirrel.mac stacked update behavior to old staged updates. #49365 (Also in 39, 40, 41)