Adding a new property to prevent script from being loaded in "modules" mode
Scripts in module mode need to be abide by the Same Origin Policy (CORS headers are used to load them) This can cause issues on some setups. This commit adds a new "scriptDisableModuleSupport" that can be used to disable the "modules" mode. Closes #1721
This commit is contained in:
parent
55da4d5f20
commit
9425fd70c0
14 changed files with 353 additions and 9 deletions
5
front/dist/iframe.html
vendored
5
front/dist/iframe.html
vendored
|
@ -11,7 +11,10 @@
|
|||
const scriptUrl = urlParams.get('script');
|
||||
const script = document.createElement('script');
|
||||
script.src = scriptUrl;
|
||||
script.type = "module";
|
||||
|
||||
if (urlParams.get('moduleMode') === 'true') {
|
||||
script.type = "module";
|
||||
}
|
||||
document.head.append(script);
|
||||
</script>
|
||||
</head>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue