This commit is contained in:
2020-03-18 18:19:30 +08:00
parent 3f3632fa31
commit 6d669324d5
4 changed files with 6 additions and 5 deletions
+1 -1
View File
@@ -28,7 +28,7 @@ function createWindow () {
// in an array if your app supports multi windows, this is the time // in an array if your app supports multi windows, this is the time
// when you should delete the corresponding element. // when you should delete the corresponding element.
mainWindow = null mainWindow = null
}) });
mainWindow.webContents.openDevTools() mainWindow.webContents.openDevTools()
} }
+2 -1
View File
@@ -4,7 +4,8 @@
"description": "A minimal Electron application", "description": "A minimal Electron application",
"main": "main.js", "main": "main.js",
"scripts": { "scripts": {
"start": "electron ." "start": "electron .",
"package":"electron-packager . rikaze --platform=win32 --arch=x64 --icon=computer.ico --out=./out --asar --app-version=0.0.1 --overwrite --ignore=node_modules"
}, },
"repository": "https://github.com/electron/electron-quick-start", "repository": "https://github.com/electron/electron-quick-start",
"keywords": [ "keywords": [
+3 -3
View File
@@ -4,7 +4,7 @@
// `nodeIntegration` is turned off. Use `preload.js` to // `nodeIntegration` is turned off. Use `preload.js` to
// selectively enable features needed in the rendering // selectively enable features needed in the rendering
// process. // process.
let myNotification = new Notification('标题', {
body: '通知正文内容'
const { BrowserWindow } = require('electron'); });
View File