Fix standalone tag when data-type is not set. (#11624)
This commit is contained in:
parent
242d9e0b20
commit
05804b166c
@ -53,7 +53,7 @@ function buildBabelOptions(script, filename) {
|
||||
*/
|
||||
function run(transformFn, script) {
|
||||
const scriptEl = document.createElement("script");
|
||||
if (typeof script.type !== "undefined") {
|
||||
if (script.type) {
|
||||
scriptEl.setAttribute("type", script.type);
|
||||
}
|
||||
scriptEl.text = transformCode(transformFn, script);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user