ELECTRONJS: cant access app in preload script

Viewed 14

I have a preloadscript and I need to access app. For some reason im getting this error.

enter image description here

const { contextBridge, app} = require('electron');

  contextBridge.exposeInMainWorld('mainMethods', {
     quit: () => {
        console.log(app.getPath())
     }
})

0 Answers
Related