fs.existsSync
danielehrhardt opened this issue · 2 comments
danielehrhardt commented
I am getting the Following Error when i import:
import { openSystemPreferences } from 'electron-util';
index.js:7 Uncaught TypeError: fs.existsSync is not a function
at getElectronPath (index.js:7)
webPreferences: {
nodeIntegration: true,
allowRunningInsecureContent: serve ? true : false,
contextIsolation: false,
enableRemoteModule: true,
},
sindresorhus commented
That error is coming from Electron, not this package. You're going to have to do some digging yourself.
danielehrhardt commented
Stuff need to be imported like this:
openSystemPreferences = require('electron-util');