chore: update to standard 12
This commit is contained in:
parent
9e85bdb02c
commit
558fff69e7
198 changed files with 4455 additions and 2940 deletions
|
@ -19,11 +19,11 @@ scripts to be able to use those modules.
|
|||
The main process script is like a normal Node.js script:
|
||||
|
||||
```javascript
|
||||
const {app, BrowserWindow} = require('electron')
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
let win = null
|
||||
|
||||
app.on('ready', () => {
|
||||
win = new BrowserWindow({width: 800, height: 600})
|
||||
win = new BrowserWindow({ width: 800, height: 600 })
|
||||
win.loadURL('https://github.com')
|
||||
})
|
||||
```
|
||||
|
@ -36,7 +36,7 @@ extra ability to use node modules:
|
|||
<html>
|
||||
<body>
|
||||
<script>
|
||||
const {app} = require('electron').remote
|
||||
const { app } = require('electron').remote
|
||||
console.log(app.getVersion())
|
||||
</script>
|
||||
</body>
|
||||
|
@ -52,7 +52,7 @@ As of 0.37, you can use
|
|||
built-in modules.
|
||||
|
||||
```javascript
|
||||
const {app, BrowserWindow} = require('electron')
|
||||
const { app, BrowserWindow } = require('electron')
|
||||
|
||||
let win
|
||||
|
||||
|
@ -67,7 +67,7 @@ destructuring to access the individual modules from `electron`.
|
|||
|
||||
```javascript
|
||||
const electron = require('electron')
|
||||
const {app, BrowserWindow} = electron
|
||||
const { app, BrowserWindow } = electron
|
||||
|
||||
let win
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue