Jump to content
RAGE Multiplayer Community

[C# Blazor] Blazor does not support package:// protocol


Recommended Posts

I've heard many times that it is possible to use Blazor for the UI, but I'm struggling to get it working.

I'm trying to create a Blazor WebAssembly app and run it under CEF. From what I see during the initialization Blazor tries to fetch a configuration file blazor.boot.json and to do that it uses the same URL root as the one that is currently running in CEF. However the fetch operation does not support the package:// protocol that is used when the browser window is created and this results in the following error:

blazor.webassembly.js:1 Fetch API cannot load package://package_name/wwwroot/_framework/blazor.boot.json. URL scheme "package" is not supported.
(anonymous) @ blazor.webassembly.js:1
blazor.webassembly.js:1 TypeError: Failed to fetch
    at Function.<anonymous> (blazor.webassembly.js:1)
    at blazor.webassembly.js:1
    at Object.next (blazor.webassembly.js:1)
    at blazor.webassembly.js:1
    at new Promise (<anonymous>)
    at blazor.webassembly.js:1
    at Function.initAsync (blazor.webassembly.js:1)
    at blazor.webassembly.js:1
    at blazor.webassembly.js:1
    at Object.next (blazor.webassembly.js:1)

Is there any workaround for this issue? Is Blazor actually supported?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Create New...