InventoryTrack/renderer.js
2022-11-02 22:16:03 -04:00

14 lines
389 B
JavaScript

const {ipcRenderer} = require('electron')
document.querySelector('#submit').addEventListener('click', function() {
let username = document.getElementById("email").value;
let password = document.getElementById("password").value;
ipcRenderer.send('login-request', [username, password]);
ipcRenderer.on('login-reply', (event, arg) => {
console.log(arg)
})
});