electron/docs/fiddles/system/system-app-user-information/app-information/renderer.js
Milan Burda 08bbff5361
docs: handle opening links in the default browser in main.js (part #2) (#39473)
docs: handle opening links in the default browser in main.js
2023-08-14 10:04:29 +02:00

9 lines
325 B
JavaScript

const { ipcRenderer } = require('electron')
const appInfoBtn = document.getElementById('app-info')
appInfoBtn.addEventListener('click', async () => {
const path = await ipcRenderer.invoke('get-app-path')
const message = `This app is located at: ${path}`
document.getElementById('got-app-info').innerHTML = message
})