Skip to content

Commit ec8206a

Browse files
CR: Comment
1 parent cf9018a commit ec8206a

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Components/Web.JS/src/Platform/WebAssemblyResourceLoader.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ export class WebAssemblyResourceLoader {
1111
credentials: 'include'
1212
});
1313

14+
// Define a separate cache for each base href, so we're isolated from any other
15+
// Blazor application running on the same origin. We need this so that we're free
16+
// to purge from the cache anything we're not using and don't let it keep growing,
17+
// since we don't want to be worst offenders for space usage.
1418
const relativeBaseHref = document.baseURI.substring(document.location.origin.length);
1519
const cacheName = `blazor-resources-${relativeBaseHref}`;
1620
return new WebAssemblyResourceLoader(

0 commit comments

Comments
 (0)