Search code examples
c#azure-web-app-serviceblazorprogressive-web-appsblazor-webassembly

Convert an existing Blazor WebAssembly (hosted) App into a PWA Problems


I recently created a Blazor WebAssembly (hosted) app. Now I needed a notification service. I converted my existing project strictly according to the documentation.

When I start debugging in VS2019, there is no PWA functionality in the App and when I deploy it in Azure App Services, the functionality appears. The Data is provided by the databse but when I click a button, nothing happens at all. No SignalR processing, no database processing.

I suspected that in local debugging the service-worker.js doesn't work well and therefore there is no PWA in sight. When I deploy it the PWA works because of the switch to the service-worker.published.js.

Why does PWA not work in debugging?

If it is working, why is the application not working anymore?


Solution

  • Based on my research I found that there is an on-going issue for PWA with VisualStudio-2019 in Github.

    But you can use VisualStudio-2017 for debugging the PWA application by following the this link.