mirror of
https://gitlab.rlp.net/proj-wise2526-video2document/video2document.git
synced 2026-06-15 18:01:52 +02:00
Implemented functionality to have the UI be able to communicate with the backend
This commit is contained in:
@@ -5,7 +5,10 @@ const { contextBridge, ipcRenderer, webUtils } = require('electron')
|
||||
try {
|
||||
contextBridge.exposeInMainWorld("explorer", {
|
||||
onFileDrop: (file) => webUtils.getPathForFile(file)
|
||||
})
|
||||
})
|
||||
contextBridge.exposeInMainWorld("extractor", {
|
||||
extract: (file) => ipcRenderer.send("extract", file)
|
||||
})
|
||||
} catch (error) {
|
||||
console.log("Error in preload.js");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user