Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade to Electron 13. Remove electron-webpack dependency. #160

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

szTheory
Copy link
Owner

No description provided.

@szTheory szTheory added the dependencies Pull requests that update a dependency file label Jul 20, 2021
@szTheory szTheory changed the title Remove electron-webpack dependency Upgrade to Electron 13. Remove electron-webpack dependency. Jul 20, 2021
@szTheory
Copy link
Owner Author

Currently blocked by lack of ES module support in Electron 13, even it is based on Node 14 which is supposed to support ES modules. Gives this error:

App threw an error during load
Error [ERR_REQUIRE_ESM]: Must use import to load ES Module: /projects/exifcleaner/dist/src/main/index.js
require() of ES modules is not supported.
require() of /projects/exifcleaner/dist/src/main/index.js from projects/exifcleaner/node_modules/electron/dist/Electron.app/Contents/Resources/default_app.asar/main.js is an ES module file as it is a .js file whose nearest parent package.json contains "type": "module" which defines all .js files in that package scope as ES modules.
Instead rename index.js to end in .cjs, change the requiring code to use import(), or remove "type": "module" from /projects/exifcleaner/dist/package.json.

See this issue on the Electron issue tracker: electron/electron#21457

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant