Skip to content

Commit

Permalink
Fix URL handling in ScriptHandler (#6639) (#6655)
Browse files Browse the repository at this point in the history
  • Loading branch information
marklundin authored and Martin Valigursky committed Jun 5, 2024
1 parent 0d79d5e commit 96c4a8b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/framework/handlers/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ class ScriptHandler extends ResourceHandler {
_loadModule(url, callback) {

// if we're in the browser, we need to use the full URL
const baseUrl = platform.browser ? window.location.origin : import.meta.url;
const baseUrl = platform.browser ? window.location.origin + window.location.pathname : import.meta.url;
const importUrl = new URL(url, baseUrl);

// @ts-ignore
Expand Down

0 comments on commit 96c4a8b

Please sign in to comment.