add session to id of clinic
This commit is contained in:
parent
3b07b3ab5b
commit
58da225b04
25
main.js
25
main.js
@ -1,24 +1,25 @@
|
||||
const electron = require("electron");
|
||||
const { app, BrowserWindow } = electron;
|
||||
const Store = require("electron-store");
|
||||
const { app, BrowserWindow, session } = electron;
|
||||
|
||||
let mainWindow;
|
||||
const store = new Store();
|
||||
let mainApp;
|
||||
|
||||
store.set('unicorn', '🦄');
|
||||
console.log(store.get('unicorn'));
|
||||
app.allowRendererProcessReuse = true;
|
||||
|
||||
app.on("ready", () => {
|
||||
mainWindow = new BrowserWindow({
|
||||
|
||||
mainApp = new BrowserWindow({
|
||||
width: 1000,
|
||||
height: 700
|
||||
});
|
||||
|
||||
mainWindow.setFullScreen(true)
|
||||
mainWindow.setTitle("DR PROFESSIONAL CLINIC");
|
||||
mainWindow.loadURL("http://clinic.cubetiq.online");
|
||||
mainApp.webContents.executeJavaScript(`localStorage.setItem("author", "Sambo Chea <sombochea@cubetiqs.com>")`)
|
||||
mainApp.webContents.executeJavaScript(`localStorage.setItem("IS_ELECTRON", true)`)
|
||||
|
||||
mainWindow.on("closed", () => {
|
||||
mainWindow = null;
|
||||
mainApp.setFullScreen(true)
|
||||
mainApp.setTitle("DR PROFESSIONAL CLINIC");
|
||||
mainApp.loadURL("http://clinic.cubetiq.online");
|
||||
|
||||
mainApp.on("closed", () => {
|
||||
mainApp = null;
|
||||
});
|
||||
});
|
||||
|
@ -20,6 +20,8 @@
|
||||
}
|
||||
},
|
||||
"dependencies": {
|
||||
"electron-browser-storage": "^1.0.6",
|
||||
"electron-localstorage": "^1.0.5",
|
||||
"electron-store": "^5.1.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
10
yarn.lock
10
yarn.lock
@ -508,6 +508,11 @@ ejs@^3.0.1:
|
||||
resolved "https://registry.yarnpkg.com/ejs/-/ejs-3.0.1.tgz#30c8f6ee9948502cc32e85c37a3f8b39b5a614a5"
|
||||
integrity sha512-cuIMtJwxvzumSAkqaaoGY/L6Fc/t6YvoP9/VIaK0V/CyqKLEQ8sqODmYfy/cjXEdZ9+OOL8TecbJu+1RsofGDw==
|
||||
|
||||
electron-browser-storage@^1.0.6:
|
||||
version "1.0.6"
|
||||
resolved "https://registry.yarnpkg.com/electron-browser-storage/-/electron-browser-storage-1.0.6.tgz#1507be52a38c726f9d3f138c79260bbee58f4f87"
|
||||
integrity sha512-ap986HDJNPAangFsG0w0KWMal2GSOXEShMXho5Ory9XG+u2CIfP76nI1yruSemTCvDr+Rg4zpC8Ec9S349eUgw==
|
||||
|
||||
electron-builder@^22.3.2:
|
||||
version "22.3.2"
|
||||
resolved "https://registry.yarnpkg.com/electron-builder/-/electron-builder-22.3.2.tgz#902d150fc0670cb90213262e5e0aa3c4f299ffa4"
|
||||
@ -527,6 +532,11 @@ electron-builder@^22.3.2:
|
||||
update-notifier "^4.0.0"
|
||||
yargs "^15.1.0"
|
||||
|
||||
electron-localstorage@^1.0.5:
|
||||
version "1.0.5"
|
||||
resolved "https://registry.yarnpkg.com/electron-localstorage/-/electron-localstorage-1.0.5.tgz#910df498b3b125519a00accc99cd770275978822"
|
||||
integrity sha512-wmEcjZdyFI1YFlCtU8g8JP0FJ02WuIrUyNwxu0Mn7Be5YiFowuejeudgWMTaa2zd2qJlQCLmA3bj8pydIoti7Q==
|
||||
|
||||
electron-publish@22.3.2:
|
||||
version "22.3.2"
|
||||
resolved "https://registry.yarnpkg.com/electron-publish/-/electron-publish-22.3.2.tgz#d2e60caf7a9643fe57e501c20acaf32c737b1c50"
|
||||
|
Loading…
Reference in New Issue
Block a user