Electron 6.0.0
Das Electron-Team freut sich über die Veröffentlichung von Electron 6.0.0! Sie können es mit npm über npm install electron@latest
installieren oder von unserer Release-Website herunterladen. Der Release ist voll mit Upgrades, Korrekturen und neuen Features. Wir können nicht warten, was du mit ihnen baust! Lesen Sie weiter für Details zu dieser Version und teilen Sie bitte Ihr Feedback!
Was ist neu
Today marks a first for the Electron project: this is the first time we've made a stable Electron release on the same day as the corresponding Chrome stable release! 🎉
Much of Electron's functionality is provided by the core components of Chromium, Node.js, and V8. Electron keeps up-to-date with these projects to provide our users with new JavaScript features, performance improvements, and security fixes. Each of these packages has a major version bump in Electron 6:
- Chromium
76.0.3809.88
- Node.js
12.4.0
- V8
7.6.303.22
This release also includes improvements to Electron's APIs. The release notes have a more complete list, but here are the highlights:
Promisification
Electron 6.0 continues the modernization initiative started in 5.0 to improve Promise support.
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:
dialog.showMessageBox()
/dialog.showMessageBoxSync()
#17298dialog.showOpenDialog()
/dialog.showOpenDialogSync()
#16973dialog.showSaveDialog()
/dialog.showSaveDialogSync()
#17054
These functions now return Promises:
app.dock.show()
#16904
Electron Helper (Renderer).app
, Electron Helper (GPU).app
and Electron Helper (Plugin).app
In order to enable the hardened runtime, which restricts things like writable-executable memory and loading code signed by a different Team ID, special code signing entitlements needed to be granted to the Helper.
To keep these entitlements scoped to the process types that require them, Chromium added three new variants of the Helper app: one for renderers (Electron Helper (Renderer).app
), one for the GPU process (Electron Helper (GPU).app
) and one for plugins (Electron Helper (Plugin).app
).
Folks using electron-osx-sign
to codesign their Electron app shouldn't have to make any changes to their build logic. If you're codesigning your app with custom scripts, you should ensure that the three new Helper applications are correctly codesigned.
In order to package your application correctly with these new helpers you need to be using electron-packager@14.0.4
or higher. If you are using electron-builder
you should follow this issue to track support for these new helpers.
Breaking Changes
-
This release begins laying the groundwork for a future requirement that native Node modules loaded in the renderer process be either N-API or Context Aware. The reasons for this change are faster performance, stronger security, and reduced maintenance workload. Read the full details including the proposed timeline in this issue. This change is expected to be completed in Electron v11.
-
net.IncomingMessage
headers have changed slightly to more closely match Node.js behavior, particularly with the value ofset-cookie
and how duplicate headers are handled. #17517. -
shell.showItemInFolder()
now returns void and is an asynchronous call. #17121 -
Apps must now explicitly set a log path by calling the new function
app.setAppLogPath()
before usingapp.getPath('log')
. #17841
Ende der Unterstützung für 3.x.y
Per our support policy, 3.x.y has reached end of life. Developers and applications are encouraged to upgrade to a newer version of Electron.
App Feedback Programm
We continue to use our App Feedback Program for testing. Projects who participate in this program test Electron betas on their apps; and in return, the new bugs they find are prioritized for the stable release. If you'd like to participate or learn more, check out our blog post about the program.
What's Next
In the short term, you can expect the team to continue to focus on keeping up with the development of the major components that make up Electron, including Chromium, Node, and V8. Although we are careful not to make promises about release dates, our plan is release new major versions of Electron with new versions of those components approximately quarterly. The tentative 7.0.0 schedule maps out key dates in the Electron 7 development life cycle. Also, see our versioning document for more detailed information about versioning in Electron.
For information on planned breaking changes in upcoming versions of Electron, see our Planned Breaking Changes doc.