Blazor Server Side work on electronize start but not after electronize build /target win #699

Closed
opened 2026-01-29 16:46:14 +00:00 by claunia · 3 comments
Owner

Originally created by @NicolasEhrhard on GitHub (Sep 11, 2021).

Originally assigned to: @GregorBiswanger on GitHub.

Hello, i use electron.Net for my blazor project.
When i use it with electronize start, it's working perfectly, but when i try to publish it to windows ( electronize build /target win )
i've got an javascript error.

Capturer

this is my manifest.json:
{
"executable": "DakaraApp",
"splashscreen": {
"imageFile": "/wwwroot/images/Dakara.png"
},
"name": "Dakara",
"author": "Alsaris",
"singleInstance": false,
"environment": "Production",
"build": {
"appId": "com.AdminDashboard.Server.app",
"productName": "DakaraApp",
"copyright": "Copyright © 2020",
"buildVersion": "0.0.1",
"win": {
"icon": "/wwwroot/images/Dakara.png"
},
"mac": {
"icon": "/wwwroot/images/Dakara.png"
},
"linux": {
"icon": "/wwwroot/images/Dakara.png"
},
"compression": "maximum",
"directories": {
"output": "../../../bin/Desktop"
},
"extraResources": [
{
"from": "./bin",
"to": "bin",
"filter": [ "/*" ]
}
],
"files": [
{
"from": "./ElectronHostHook/node_modules",
"to": "ElectronHostHook/node_modules",
"filter": [ "
/" ]
},
"**/
"
]
}
}

Can someone help me ?

Originally created by @NicolasEhrhard on GitHub (Sep 11, 2021). Originally assigned to: @GregorBiswanger on GitHub. Hello, i use electron.Net for my blazor project. When i use it with electronize start, it's working perfectly, but when i try to publish it to windows ( electronize build /target win ) i've got an javascript error. ![Capturer](https://user-images.githubusercontent.com/33448341/132939738-47be92f1-9622-48c0-a6d7-3b212478fe12.PNG) this is my manifest.json: { "executable": "DakaraApp", "splashscreen": { "imageFile": "/wwwroot/images/Dakara.png" }, "name": "Dakara", "author": "Alsaris", "singleInstance": false, "environment": "Production", "build": { "appId": "com.AdminDashboard.Server.app", "productName": "DakaraApp", "copyright": "Copyright © 2020", "buildVersion": "0.0.1", "win": { "icon": "/wwwroot/images/Dakara.png" }, "mac": { "icon": "/wwwroot/images/Dakara.png" }, "linux": { "icon": "/wwwroot/images/Dakara.png" }, "compression": "maximum", "directories": { "output": "../../../bin/Desktop" }, "extraResources": [ { "from": "./bin", "to": "bin", "filter": [ "**/*" ] } ], "files": [ { "from": "./ElectronHostHook/node_modules", "to": "ElectronHostHook/node_modules", "filter": [ "**/*" ] }, "**/*" ] } } Can someone help me ?
claunia added the bug label 2026-01-29 16:46:14 +00:00
Author
Owner

@peter-bozovic commented on GitHub (May 10, 2022):

Check the output folder of the build: Desktop\win-unpacked\resources\bin
Check the .exe file that you have there, and make sure you have the same name in the electron.manifest.json under "executable":"..."

@peter-bozovic commented on GitHub (May 10, 2022): Check the output folder of the build: `Desktop\win-unpacked\resources\bin` Check the `.exe` file that you have there, and make sure you have the same name in the `electron.manifest.json` under `"executable":"..."`
Author
Owner

@damikun commented on GitHub (Aug 26, 2022):

For people who are searching for solution... Please make sure the "executable": "YourNamespaeName", (from electron.manifest.json) match the YourNamespaeName from your .csproj file...

Also make sure that you dont use whitespaces and characters as -,/.... there because electron removes it and than app does not know what exe file to run because the name executable is different from defined in manifest...

Your executable can be find under obj/host/bin it ends with .exe

@damikun commented on GitHub (Aug 26, 2022): For people who are searching for solution... Please make sure the "executable": "YourNamespaeName", (from electron.manifest.json) match the <AssemblyName>YourNamespaeName</AssemblyName> from your .csproj file... Also make sure that you dont use whitespaces and characters as -,/.... there because electron removes it and than app does not know what exe file to run because the name executable is different from defined in manifest... Your executable can be find under obj/host/bin it ends with .exe
Author
Owner

@GregorBiswanger commented on GitHub (Mar 28, 2023):

🎉🚀 New Electron.NET version 23.6.1 released 🚀🎉

With native Electron 23 and .NET 6 support. Your problem should be fixed here. If you continue to have the problem, please let us know. Please note the correct updating of your API & CLI. Info in the README. Have fun!

@GregorBiswanger commented on GitHub (Mar 28, 2023): 🎉🚀 New Electron.NET version 23.6.1 released 🚀🎉 With native Electron 23 and .NET 6 support. Your problem should be fixed here. If you continue to have the problem, please let us know. Please note the correct updating of your API & CLI. Info in the README. Have fun!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/Electron.NET#699