Allow use of `id` attribute on in-browser script tags to propagate to compilation output
This commit is contained in:
parent
306d542600
commit
4c8796b6c9
|
@ -20,7 +20,7 @@ const currentSyndicateTarget = Syndicate.Dataspace.global;
|
||||||
const sourceCode = sourceUrl ? await (await fetch(sourceUrl)).text() : script.innerHTML;
|
const sourceCode = sourceUrl ? await (await fetch(sourceUrl)).text() : script.innerHTML;
|
||||||
|
|
||||||
const compilationResult = SyndicateCompiler.compile({
|
const compilationResult = SyndicateCompiler.compile({
|
||||||
name: sourceUrl || 'anonymous-script-tag',
|
name: sourceUrl || script.id || 'anonymous-script-tag',
|
||||||
source: sourceCode,
|
source: sourceCode,
|
||||||
module: isModule ? 'es6' : 'none',
|
module: isModule ? 'es6' : 'none',
|
||||||
runtime: isModule ? void 0 : 'Syndicate',
|
runtime: isModule ? void 0 : 'Syndicate',
|
||||||
|
|
Loading…
Reference in New Issue