How to Configure Blazor Hub Mapping in ASP.NET Core MVC App

I have an existing MVC application in which I wish to use blazor for some specific requirement. After integrating it,I realized that on the index page of the app, the razor components work just fine without problems. But when I move to another page, it will lose the blazor hub connection. I noticed it might a mapping problem because on the homepage, [appurl]/_blazor works and connects just fine. But when I go to another page, [appurl]/[controller]/_blazor tries to connect but it throws 404.
How can I get it to work for all routes on the application?

Leave a Reply

Your email address will not be published. Required fields are marked *