electron/docs/api/modernization/promisification.md
Shelley Vohr eec12b399a
feat: promisify systemPreferences notification methods (#18631)
* feat: promisify systemPreferences notification methods

* correct userInfo typedef
2019-06-06 07:47:18 -07:00

6.5 KiB

Promisification

The Electron team is currently undergoing an initiative to convert callback-based functions in Electron to return Promises. During this transition period, both the callback and Promise-based versions of these functions will work correctly, and will both be documented.

To enable deprecation warnings for these updated functions, use the process.enablePromiseAPI runtime flag.

When a majority of affected functions are migrated, this flag will be enabled by default and all developers will be able to see these deprecation warnings. At that time, the callback-based versions will also be removed from documentation. This document will be continuously updated as more functions are converted.

Candidate Functions

Converted Functions