My project runs fine on local host, but when I publish a Blazor WebAssembly app to Azure I get:
Loading module from “https://aistorybuilderstest.azurewebsites.net/_framework/dotnet.js” was blocked because of a disallowed MIME type (“text/html”).aistorybuilderstest.azurewebsites.netLoading failed for the module with source “https://aistorybuilderstest.azurewebsites.net/_framework/dotnet.js”. aistorybuilderstest.azurewebsites.net:73:52Uncaught (in promise) Error: Failed to start platform. Reason: TypeError: error loading dynamically imported module: https://aistorybuilderstest.azurewebsites.net/_framework/dotnet.js mn https://aistorybuilderstest.azurewebsites.net/_framework/blazor.webassembly.js:1
This project ran fine on Azure for months and I only made a small change to a .razor file. I had also upgraded the Nuget packages but I rolled back all those changes and it still wont work.
I created a new Blazor WebAssembly project and published to Azure and it also wont work.
It just shows:
I restored a back-up of a project that works and compared the files and I see that in the project that does not work the Dotnet.js files are missing.
Why are they missing? I have no idea :( I am running the latest Visual Studio Version 17.9.6
If I run the project locally the dotnet.js file is there and loads: