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

Cannot be compiled correctly #260

Open
JH34tem opened this issue Apr 25, 2024 · 1 comment
Open

Cannot be compiled correctly #260

JH34tem opened this issue Apr 25, 2024 · 1 comment

Comments

@JH34tem
Copy link

JH34tem commented Apr 25, 2024

I tried to compile using npm run release, but an error occurred and I couldn't find 'background. js'

⨯ Application entry file "background. js" in the "/root/weektodo/list/Linux arm64 unpacked/resources/app. sar" does not exist Seems like a wrong configuration Failed Task=build

Then, I tried changing background. js in package. json to src/background.js, this time the packaging was successful, but the runtime still reported an error.

SyntaxError: Cannot use import statement outside a module
at internalCompileFunction (node:internal/vm:73:18)
at wrapSafe (node:internal/modules/cjs/loader:1183:20)
at Module._compile (node:internal/modules/cjs/loader:1225:27)
at Module._extensions..js (node:internal/modules/cjs/loader:1324:10)
at Module.load (node:internal/modules/cjs/loader:1124:32)
at Module._load (node:internal/modules/cjs/loader:965:12)
at f._load (node:electron/js2c/asar_bundle:2:13330)
at node:electron/js2c/browser_init:2:122731
at node:electron/js2c/browser_init:2:122934
at node:electron/js2c/browser_init:2:122938

Then, "type" : "module" was tried to use to fix, node-fetch or something was downgraded to 2.6.0 or similar...

Then an error occurred

[Instead change the require of index.js, to a dynamic import() which is available in all CommonJS modules

Please tell us how to fix, thanks

@Lauryy06
Copy link

I'm having exactly the same problems, I can't compile the desktop version...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants