dotnet / aspnetcore

ASP.NET Core is a cross-platform .NET framework for building modern cloud-based web applications on Windows, Mac, or Linux.
https://asp.net
MIT License
35.19k stars 9.93k forks source link

asm.js not served by default on IIS (no mime type for .mem files) #5538

Closed TheCamel closed 5 years ago

TheCamel commented 6 years ago

Hi, with the solution i provide in #989 ;

SteveSandersonMS commented 6 years ago

To deploy to a subdirectory, you need to update your <base href> to match. This is why the deployments under TEST aren't working (notice in the network traces, it's trying to load resources from outside the test/ directory.

For the deployment to the root, you're getting a 404 on a request to _framework/asmjs/mono.js.mem. I expect that IIS doesn't have any media type configured for .mem files. I'll update this issue to track the need to configure that, if we are going to support asm.js.

As per the comments on #989, you can avoid this issue by making sure your Edge browser supports WebAssembly, which up-to-date versions of Edge do support by default.

TheCamel commented 6 years ago

you mean this line in the index.html ? base href=""

what should I use for subapp http://localhost/TEST ? because can't make it work

TheCamel commented 6 years ago

for your information, Microsoft Edge 40.15063.674.0 - update are locked by group policies and I understand you don't want yo support older version but even without console open it does not work for root app or sub app. It works only from VStudio with CtrlF5 (it takes 5 minutes to load a page...that's why i thought it was freezing) or with Chrome everywhere btw, Href is also not working for edge

blazor_deploy2

SteveSandersonMS commented 6 years ago
<base href="/TEST/" />
TheCamel commented 6 years ago

thanks; I confirm : does not work for edge...:-) Complement; with chrome on root app, can't go back to Home - no trouble on sub app

SteveSandersonMS commented 5 years ago

Closing because we're no longer supporting asm.js (because the execution speed was inadequate). People who need to support pre-WASM browsers will get better results with running the Blazor app server-side (e.g., using the server-side Blazor template).