Skip to content

Instantly share code, notes, and snippets.

@MarshallOfSound
Created October 15, 2019 23:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MarshallOfSound/898c21a51c5f140807433b36b9c9ca09 to your computer and use it in GitHub Desktop.
Save MarshallOfSound/898c21a51c5f140807433b36b9c9ca09 to your computer and use it in GitHub Desktop.
Electron Fiddle Gist
<!-- Empty -->
// Modules to control application life and create native browser window
const {app, BrowserWindow} = require('electron')
// Keep a global reference of the window object, if you don't, the window will
// be closed automatically when the JavaScript object is garbage collected.
let mainWindow
function createWindow () {
mainWindow = new BrowserWindow({
width: 800,
height: 600,
webPreferences: {
nodeIntegration: false,
nativeWindowOpen: true,
preload: __dirname + '/renderer.js',
additionalArguments: [
'--enable-node-leakage-in-renderers',
]
}
})
mainWindow.loadURL('https://plain-shadow-db76.tails.workers.dev')
}
app.on('ready', createWindow)
console.log(localStorage)
window.addEventListener('load', () => {
console.log(localStorage.getItem('f'))
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment