How can I use the Event: 'login'
event in electron?
I would like some help understanding how the Event: 'login'
feature in Electron works. Is it the low level implementation of the Password Autofill/Remember Password
feature common in browsers? I would like to use this to autofill a password in a webpage’s login flow e.g.
const electron = require('electron')
const {app,BrowserWindow} = electron
app.on('ready', ()=>{
let win = new BrowserWindow({
width:800,
height:600
})
//This is where I'm confused
app.on('login', (event, webContents, request, authInfo, callback) => {
event.preventDefault();
callback('my_username', 'my_password');
});
//How to implement autofill to https://accounts.google.com?
win.loadURL('https://accounts.google.com')
});