4cb57ad1a0
* Remove unused import of path This import gives out the error in the preload script: Error: module not found: path at preloadRequire * Removes unused import in preload script notes: Removes unused import which causes issue in preload script of drag and drop tutorial * Remove import path as it is not used in the script note: Removes import path as it is not used in the script
7 lines
188 B
JavaScript
7 lines
188 B
JavaScript
const { contextBridge, ipcRenderer } = require('electron')
|
|
|
|
contextBridge.exposeInMainWorld('electron', {
|
|
startDrag: (fileName) => {
|
|
ipcRenderer.send('ondragstart', fileName)
|
|
}
|
|
})
|