electron/docs/fiddles/native-ui/dialogs/save-dialog/renderer.js

7 lines
237 B
JavaScript

const saveBtn = document.getElementById('save-dialog')
saveBtn.addEventListener('click', async () => {
const path = await window.electronAPI.saveDialog()
document.getElementById('file-saved').innerHTML = `Path selected: ${path}`
})