Electron v6.0.0
Release Notes
Breaking Changes
Upgraded to Chromium
76.0.3809.88
, Node.js12.4.0
, and V87.6.303.22
Fixed disparity between
net
module headers and Node.js'http.IncomingMessage
headers. #17517Made
ShowItemInFolder
asynchronous with no return value. #17121Made app log directory creation opt-in with a new function
app.setAppLogsPath
. #17841Removed
hasServiceWorker
andunregisterServiceWorker
APIs from the WebContents modules. #16717
Promises
Electron 6.0 continues a project started in 5.0 to improve Promise support. See the project notes for more information.
These functions now return Promises and still support older callback-based invocation:
contentTracing.getCategories()
#16583contentTracing.getCategories()
#16583contentTracing.getTraceBufferUsage()
#16600contents.executeJavaScript()
#17312cookies.flushStore()
#16464cookies.get()
#16464cookies.remove()
#16464cookies.set()
#16464dialog.showCertificateTrustDialog()
#17181inAppPurchase.getProducts()
#17355inAppPurchase.purchaseProduct()
#17355netLog.stopLogging()
#16862session.clearAuthCache()
#17259session.clearCache()
#17185session.clearHostResolverCache()
#17229session.clearStorageData()
#17249session.getBlobData()
#17303session.getCacheSize()
#17185session.resolveProxy()
#17222session.setProxy()
#17222webContents.hasServiceWorker()
#16535webContents.printToPDF()
#16795webContents.savePage()
#16742webFrame.executeJavaScript()
#17312webFrame.executeJavaScriptInIsolatedWorld()
#17312webviewTag.executeJavaScript()
#17312
These functions now have two forms, synchronous and Promise-based asynchronous:
These functions now return Promises:
app.dock.show()
#16904
Features
Added
chrome.runtime.getManifest
API for Chrome extensions. #16891Added
<webview>.getWebContentsId()
, which does not depend of theremote
module. #17407Added
all_frames
support for Chrome extension content scripts. #17258Added
disableHtmlFullscreenWindowResize
option towebPreferences
to allow preventing window from resizing when entering HTML5 fullscreen. #17203Added
excludedFromShownWindowsMenu
property to allow for windows to be excluded from the windows menu. #17404Added
process.getSystemVersion()
, which is available in sandboxed renderers and returns the actual operating system version instead of kernel version on macOS. #16599Added
process.versions.electron
to get the electron version in the forked process. #16450Added
renderer-process-crashed
event toapp
, which is emitted when any renderer process crashes. #17315Added
requestingUrl
andisMainFrame
properties to the permission request and permission check handlers details objects so that apps can check the origin of the requesting frame rather than the root frame. #18772Added
systemPreferences.getAnimationSettings()
returning system animation settings provided by Chromium. #17382Added
tray.getTitle()
to allow users to see the title set next to the status bar icon on macOS. #17385Added a new Event property
triggeredByAccelerator
, which is called back in customclick
events onMenuItems
. #16954Added ability disable fetching thumbnails for in
desktopCapturer.getSources()
. #14906Added additional error information to errors thrown when using the
remote
module. #17851Added an option to enable
MenuItems
on macOS to work optionally whenvisible: false
. #16853Added file preview for file picker in Linux. #16447
Added flexible autoresize option for
BrowserView
s inBrowserWindow
. #16184Added native Touch ID authentication support for macOS. #16707
Added new
app.allowRendererProcessReuse
property that allows apps to disable the site instance overrides Electron has patched into Chromium. This can be used to prevent the automatic renderer process restarting that Electron currently does. #18554Added new
app.userAgentFallback
property to allow setting the app's useragent globally. #18473Added new
monochrome
,internal
,acceleratorEnabled
,colorDepth
anddepthPerComponent
properties to the Display API Structure. #16870Added new inspectSharedWorker() API to enable opening devtools for a shared worker. #16615
Added safer
nativeImage.createFromBitmap()
, which does not decode PNG/JPEG. #17337Added support for Scroll Lock accelerator. #16873
Added world isolation to Chrome extension content scripts. #17032
Allowed setting working directory in
app.setUserTasks()
/app.setJumpList()
. #18291Enabled
NodeIntegrationInSubFrames
option usage forwebview
tags. #17226Exposed
colorSpace
to theDisplay
object. #17405Feat: add native emoji and color picker methods for Windows and macOS. #17359
Implemented
BrowserWindow.moveTop()
on Linux/X11. #16629Moved
webFrame
custom scheme APIs to browser process underprotocol
. #16416Process now emits 'loaded' event in sandboxed renderers. #17680
Fixes
systemPreferences.isDarkMode()
now correctly detects dark mode on macOS Catalina. #18958Added missing
'page-title-updated'
event onwebContents
to documentation. Also fixed forwarding of theexplicitSet
argument when emitted onBrowserWindow
. #18319Backported a Node.js patch that fixes an http/2 memory leak:. #18882
Corrected a reversal of cancellation values in
showSaveDialog
on the Windows platform. #18383Corrected the boolean cancellation value for
showOpenDialog
on Windows. #18509DevTools Extensions now load correctly. #17614
Enabled autofill popups on macOS. #16308
Ensured that
webContents.hasServiceWorker()
rejects with an error for invalid URLs. #16571Ensured using the
--inspect-brk
argument does not cause a crash. #19332Fixed Chrome extension content scripts not loading in sandboxed renderer. #16218
Fixed
<webview>
not working in scriptable popups whennativeWindowOpen
is enabled. #19218Fixed
app.getAppPath()
returning default-app path when runningelectron app
with no package.json orelectron app/index.js
. Now the directory containing the executed file is returned. #18888Fixed
beginFrameSubscription
returning blurred images on HiDPI displays. #17444Fixed
fs.promises
APIs not working with ASAR paths. #18114Fixed
new-window
event not being emitted from a link withtarget="_blank"
in a sandboxed<webview>
#18556Fixed
webContents.print()
callback not returning boolean correctly in all cases. #18803Fixed
webFrame.setSpellCheckProvider
memory leak. #16448Fixed
window.open()
not returningnull
whenallowpopups
was not set in a sandboxedwebview
#18556Fixed
window.opener
null after cross-origin navigation. #18624Fixed a crash in
systemPreferences.getAccentColor()
. #18195Fixed a crash when failed to get devices in desktopCapturer on Windows. #17973
Fixed a dialog crash when no BrowserWindow was passed. #18381
Fixed a possible crash on exit. #17879
Fixed a regression in Kerberos SPN generation. In the M69 upgrade, the default for the
enable_negotiate_port
option was inadvertently changed from false to true; this restores the former behavior and aligns with Chromium. #18285Fixed accidental breaking API change in the deprecated
dialog.*
methods. #18724Fixed an issue on Windows where calling
.show()
on a BrowserWindow did not focus the window. #18081Fixed an issue preventing the Flash plugin from loading on Linux. #17823
Fixed an issue where tray.destroy was not working properly on some linux distros. #18218
Fixed autohide taskbar not showing when frameless window is maximized. #18373
Fixed bug where notifications with same tag wouldn't show more than once when first notification was auto dismissed in Windows 7. #18740
Fixed building with
enable_run_as_node
disabled. #18892Fixed case where the Promise returned by
loadURL
andloadFile
would be rejected withERR_ABORTED
if you triggered a virtual navigation before the page had finished loading. E.g. Usedhistory.pushState
or setlocation.hash
. #18143Fixed crash in BrowserWindow destructor after
win.webContents.destroy()
. #18793Fixed crash that could occur while certain chrome devtools extensions were loaded. #19105
Fixed crash when Electron run from SMB network share. #17909
Fixed crash when creating certain types of windows in the
display-*
events. #19022Fixed crash when quitting Electron with an inspector attached. #18077
Fixed crash when starting with
--disable-gpu
. #18904Fixed electron.zip size increase regression on Linux (compared to Electron 3) by stripping swiftshader libraries (
libEGL.so
,libGLESv2.so
). #18600Fixed exiting html fullscreen mode for embedded contents. #18775
Fixed inconsistent behavior where modifying the buffer would change
nativeImage
pixels, while decoded PNG / JPEG data is a copy. #17843Fixed issue where
getEffectiveApperance
andgetAppLevelAppearance
would returnunknown
instead of the correct value sometimes. #18690Fixed issue where
require('timers').setTimeout
would sometimes never fire in the renderer process. #18961Fixed issue where
shell.openExternal
would not activate opened window on macOS. #18722Fixed issue where sandboxed renderers could sometimes leak globals outside of the preload script. #17712
Fixed issues where some
chrome://*
URLs would not render correctly. #18552Fixed loading of
node_modules
inside ASAR files. #18192Fixed macOS breakpad symbol files to include non-public symbols. #19155
Fixed offscreen rendering not working with viz compositor. #17538
Fixed race condition in the
desktopCapturer
module where some requests for sources would never be resolved or unhandled exceptions would be thrown in the main process. #18042Fixed race condition where the
remote
module would sometimes fail to fetch properties of a remote object. #17464Fixed random flicker that occurred on macOS when performing fullscreen or workspace transitions. #18885
Fixed setting src on
<webview>
being too slow. #19190Fixed silent printing across platforms. #19037
Fixed some chrome extension communication (
MessagePort.postMessage
) not working. #19106Fixed the
input[type=file]
element not showing a file dialog. #18341Fixed the callback of
beginFrameSubscription
passingBuffer
instead ofNativeImage
. #17548Focus methods no longer steal focus when users are active on other apps. #16400
Improved the way frameless windows are handled on Windows. #16596
Injected chrome extensions that have content scripts with a
.
in thepattern
field now treat it as a raw.
instead of a wildcard. #17593Migrated crashReporter to use crashpad on Windows. #18766
Preloaded scripts for internal
<iframe>
in<webview>
are no longer executed whennodeIntegrationInSubFrames
is enabled. #19298Removed inadvertently-included mojom.js files from distribution bundle. #18486
Removed incorrectly published internal V8 symbols and CRT methods from node.lib, causing heap corruptions with Node.js modules using the dynamic CRT on Windows. #18619
Removed non-existent
gpu-crashed
event on<webview>
. #17317Spellcheck providers are now (again) called with contractions and their parts. #18538
The
prefers-color-scheme
CSS media query now works correctly. #19250.executeJavaScript
will never leave a Promise dangling now, scripts that fail to execute will correctly be rejected. #18714Uint8Array
andUint16Array
can now be sent correctly in Chrome ExtensionMessagePort
instances. #19252Fixed popup.location.* setters when nativeWindowOpen is disabled. #19494
Fixed an issue where windows symbol files were changed in a way that was incompatible with some symbolication tools. #19504
Fixed issue where sometimes asynchronous node.js methods such as http, setImmediate and fs wouldn't call their callbacks for an incredibly long amount of time. #19467
Fixed window menu background color when in dark mode on Windows 10. #19505
Other Changes
Replaced
powerMonitor
querySystemIdleState
andquerySystemIdleTime
with synchronous APIs. #17144Added experimental support for building for Windows on Arm. #18625
Converted
accessibilitySupportEnabled
to a proper JS property onapp
. #17362Converted
applicationMenu
to a proper JS property on theapp
module. #17361Deprecated the options argument to session.clearAuthCache. #18131
Enabled
sandbox
and disabledremote
module in default_app. #17318Enabled sandboxing of devtools and chrome extension background script host renderers. #16864
Removed Vulkan mock ICD from electron.zip, which is only meant to be used for Chromium development. #18596
Removed Vulkan validation layers DLLs from electron.zip, which are only meant to be used for Chromium development. #18062
Removed deprecated modules internally using
remote.require
in sandboxed renderer context. Useremote.require
explicitly instead (unless the remote module is disabled). #15957Removed native mksnapshot binaries for arm/arm64 as they no longer work. #17561
Removed special handling that forced
dialog
methods called over theremote
module to return their result synchronously but not block the main process. #17412The
clipboard
module in renderers no longer depends on theremote
module on Linux. #17200Improved the exception message thrown when
require
fails in sandboxed renderers. #17413