You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
BREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.
This is no longer the case. Verify if you need this module and configure a polyfill for it.
If you want to include a polyfill, you need to:
- add a fallback 'resolve.fallback: { "path": require.resolve("path-browserify") }'
- install 'path-browserify'
If you don't want to include a polyfill, you can use an empty module like this:
resolve.fallback: { "path": false }
resolve 'path' in '/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron'
Parsed request is a module
using description file: /Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/package.json (relative path: .)
Field 'browser' doesn't contain a valid alias configuration
resolve as module
looking for modules in /Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules
single file module
using description file: /Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/package.json (relative path: ./node_modules/path)
no extension
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules/path doesn't exist
.js
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules/path.js doesn't exist
.ts
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules/path.ts doesn't exist
.jsx
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules/path.jsx doesn't exist
.tsx
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules/path.tsx doesn't exist
.css
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules/path.css doesn't exist
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/electron/node_modules/path doesn't exist
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/node_modules doesn't exist or is not a directory
looking for modules in /Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules
single file module
using description file: /Users/mchalyi/Projects/uu3jrd/file-messenger/package.json (relative path: ./node_modules/path)
no extension
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/path doesn't exist
.js
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/path.js doesn't exist
.ts
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/path.ts doesn't exist
.jsx
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/path.jsx doesn't exist
.tsx
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/path.tsx doesn't exist
.css
Field 'browser' doesn't contain a valid alias configuration
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/path.css doesn't exist
/Users/mchalyi/Projects/uu3jrd/file-messenger/node_modules/path doesn't exist
/Users/mchalyi/Projects/uu3jrd/node_modules doesn't exist or is not a directory
/Users/mchalyi/Projects/node_modules doesn't exist or is not a directory
/Users/mchalyi/node_modules doesn't exist or is not a directory
/Users/node_modules doesn't exist or is not a directory
/node_modules doesn't exist or is not a directory
@ ./node_modules/electron-unhandled/index.js 2:33-52 15:23-42 35:19-38
@ ./src/renderer/index.tsx 18:45-74
So basically the problem here is that node APIs are not polyfilled any more. I guess recommended way to fix this, would be to extract part which is intended for rendrer, to something like unhandledRenderer and do not import what is not needed.
Would you accept PR on such change? This is super breaking change.
The text was updated successfully, but these errors were encountered:
Well this is "problem" with every new electron development. I guess nobody would like to introduce polyfills in their code just because library references something and then do not use. But okay. Anyways, it seems like it faster to implement just in application.
Error message:
So basically the problem here is that node APIs are not polyfilled any more. I guess recommended way to fix this, would be to extract part which is intended for rendrer, to something like
unhandledRenderer
and do not import what is not needed.Would you accept PR on such change? This is super breaking change.
The text was updated successfully, but these errors were encountered: