electron-userland / electron-json-storage

:package: Easily write and read user settings in Electron apps
1.44k stars 80 forks source link

fs.existsSync is not a function #61

Closed gizburdt closed 7 years ago

gizburdt commented 7 years ago

Hi,

When using the plugin I get this console error: fs.existsSync is not a function. Also get this error while compiling code with Webpack: Error: Can't resolve 'fs' in '/Users/Gijs/Server/anvil/node_modules/electron-json-storage/lib.

Am I doing something wrong?

jviotti commented 7 years ago

Looks like a Webpack configuration issue. fs is a node built-in module. Maybe target: 'node' helps?