electron/docs/fiddles/native-ui/external-links-file-manager/renderer.js

11 lines
335 B
JavaScript
Raw Normal View History

2020-08-27 14:31:51 +00:00
const exLinksBtn = document.getElementById('open-ex-links')
const fileManagerBtn = document.getElementById('open-file-manager')
fileManagerBtn.addEventListener('click', (event) => {
window.electronAPI.openHomeDir()
2020-08-27 14:31:51 +00:00
})
exLinksBtn.addEventListener('click', (event) => {
window.electronAPI.openExternal('https://electronjs.org')
})