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
I'm not sure how this ever worked before, but the new URL() is called with .\file:\C:\Users\MyUser\AppData\Local\Temp\2tOTtWToAwGi5zLwSqEL7iitega\resources\app.asar\index.html
My soltution is to replace L41 with:
let joinedPath = path.join(__dirname, pathIndex)
const url = new URL (`file:${path.sep}${path.sep}${joinedPath}`);
And it'll work again. (Tested only on windows)
Problem appears with the upgrade from 33.4.1 to 34.2.0. Other previous verions like 32.3.1, 31.7.7, 30.5.1 worked without a problem.
The text was updated successfully, but these errors were encountered:
Rai-Rai
changed the title
Electron 34 leads to Uncaught Exception when executing app build with electron:build
Electron 34 leads to Uncaught Exception when executing app build with electron:build (with solution)
Feb 22, 2025
Steps to reproduce
Upgrade to electron 34.2.0 and build the app with
npm run electron:build
Java script error occures if the created .exe is started:
✔️ Expected Behavior
Application starts correctly
🔍 Additional context
Problem is caused here:
angular-electron/app/main.ts
Line 41 in 28b095b
I'm not sure how this ever worked before, but the
new URL()
is called with.\file:\C:\Users\MyUser\AppData\Local\Temp\2tOTtWToAwGi5zLwSqEL7iitega\resources\app.asar\index.html
My soltution is to replace L41 with:
And it'll work again. (Tested only on windows)
Problem appears with the upgrade from 33.4.1 to 34.2.0. Other previous verions like 32.3.1, 31.7.7, 30.5.1 worked without a problem.
The text was updated successfully, but these errors were encountered: