mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
docs: added session-created event documentation (backport: 2-0-x) (#14439)
* Added session-created event documentation
Emitted at 1c0ea0286e/lib/browser/api/session.js (L21)
* Removed trailing spaces
This commit is contained in:
@@ -365,6 +365,23 @@ assistive technologies, such as screen readers, are enabled or disabled.
|
||||
See https://www.chromium.org/developers/design-documents/accessibility for more
|
||||
details.
|
||||
|
||||
### Event: 'session-created'
|
||||
|
||||
Returns:
|
||||
|
||||
* `event` Event
|
||||
* `session` [Session](session.md)
|
||||
|
||||
Emitted when Electron has created a new `session`.
|
||||
|
||||
```javascript
|
||||
const {app} = require('electron')
|
||||
|
||||
app.on('session-created', (event, session) => {
|
||||
console.log(session)
|
||||
})
|
||||
```
|
||||
|
||||
## Methods
|
||||
|
||||
The `app` object has the following methods:
|
||||
|
||||
Reference in New Issue
Block a user