The purpose of this repository is to have a minimalist working example of an issue with Blazor WASM under a non-default base path URL and lazy loading assemblies with static resources.
Simply just clone the repository and debug. The site is hosted at a base path of /lazy-loading/
and the lazy loaded resource/page is at /lazy-loading/external
.
When first loading, pull up the browser developer tools and you will see two requests attempting to pull down the LazyLoadThis...bundle.scp.css
file. First one succeeds, second one fails. Since the second one fails, the first one is overwritten with the "result", which causes any reference to the file not to work.
The following screenshot shows the (filtered) requests when navigating to the base path URL:
The following screenshot shows the (filtered) requests when navigating to the lazy loaded path:
- The static resources of the lazy loaded assembly not to be pulled down on initial load.
- The pulling of such resources to adhere to the base path URL set in the index.html file.