mirror of
https://github.com/frappe/books.git
synced 2024-11-09 23:30:56 +00:00
Updated frappejs packages to work with node to v12
This commit is contained in:
parent
a91b4a274c
commit
5032f0397c
9879
package-lock.json
generated
9879
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -20,7 +20,8 @@
|
||||
"dist/electron"
|
||||
],
|
||||
"dmg": {
|
||||
"contents": [{
|
||||
"contents": [
|
||||
{
|
||||
"x": 410,
|
||||
"y": 150,
|
||||
"type": "link",
|
||||
@ -58,7 +59,8 @@
|
||||
},
|
||||
"dependencies": {
|
||||
"cross-env": "^5.2.0",
|
||||
"frappejs": "github:frappe/frappejs",
|
||||
"file-saver": "^2.0.2",
|
||||
"frappejs": "github:thefalconx33/frappejs#test",
|
||||
"nodemailer": "^4.7.0",
|
||||
"popper.js": "^1.14.4",
|
||||
"vue-color": "^2.7.0",
|
||||
|
@ -1,20 +1,17 @@
|
||||
const {
|
||||
app,
|
||||
BrowserWindow
|
||||
} = require('electron');
|
||||
const { app, BrowserWindow } = require('electron');
|
||||
const setupMenu = require('./menu');
|
||||
|
||||
let mainWindow
|
||||
let winURL
|
||||
let mainWindow;
|
||||
let winURL;
|
||||
|
||||
if (process.env.NODE_ENV !== 'development') {
|
||||
global.__static = require('path').join(__dirname, '/static').replace(/\\/g, '\\\\')
|
||||
global.__static = require('path')
|
||||
.join(__dirname, '/static')
|
||||
.replace(/\\/g, '\\\\');
|
||||
}
|
||||
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
const {
|
||||
getAppConfig
|
||||
} = require('frappejs/webpack/utils');
|
||||
const { getAppConfig } = require('frappejs/webpack/utils');
|
||||
const appConfig = getAppConfig();
|
||||
winURL = `http://localhost:${appConfig.dev.devServerPort}`;
|
||||
} else {
|
||||
@ -31,32 +28,33 @@ function createWindow() {
|
||||
height: 768,
|
||||
useContentSize: true,
|
||||
webPreferences: {
|
||||
webSecurity: false
|
||||
webSecurity: false,
|
||||
nodeIntegration: true
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
mainWindow.loadURL(winURL)
|
||||
mainWindow.loadURL(winURL);
|
||||
|
||||
mainWindow.on('closed', () => {
|
||||
mainWindow = null
|
||||
})
|
||||
mainWindow = null;
|
||||
});
|
||||
|
||||
setupMenu();
|
||||
}
|
||||
|
||||
app.on('ready', createWindow)
|
||||
app.on('ready', createWindow);
|
||||
|
||||
app.on('window-all-closed', () => {
|
||||
if (process.platform !== 'darwin') {
|
||||
app.quit()
|
||||
app.quit();
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
app.on('activate', () => {
|
||||
if (mainWindow === null) {
|
||||
createWindow()
|
||||
createWindow();
|
||||
}
|
||||
})
|
||||
});
|
||||
|
||||
// TODO:
|
||||
// Enable Auto Update
|
||||
|
Loading…
Reference in New Issue
Block a user