mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
8 lines
245 B
JavaScript
8 lines
245 B
JavaScript
const btn = document.getElementById('btn')
|
|
const filePathElement = document.getElementById('filePath')
|
|
|
|
btn.addEventListener('click', async () => {
|
|
const filePath = await window.electronAPI.openFile()
|
|
filePathElement.innerText = filePath
|
|
})
|