@unhead/shared 1.3.5 → 1.3.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +2 -11
- package/dist/index.mjs +2 -11
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -500,17 +500,8 @@ async function normaliseTag(tagName, input, e) {
|
|
|
500
500
|
tag[k] = e[k];
|
|
501
501
|
}
|
|
502
502
|
});
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
try {
|
|
506
|
-
tag[k] = JSON.parse(tag[k]);
|
|
507
|
-
} catch (e2) {
|
|
508
|
-
tag[k] = "";
|
|
509
|
-
}
|
|
510
|
-
}
|
|
511
|
-
if (typeof tag[k] === "object")
|
|
512
|
-
tag[k] = JSON.stringify(tag[k]);
|
|
513
|
-
});
|
|
503
|
+
if (tag.tag === "script" && typeof tag.innerHTML === "object")
|
|
504
|
+
tag.innerHTML = JSON.stringify(tag.innerHTML);
|
|
514
505
|
if (tag.props.class)
|
|
515
506
|
tag.props.class = normaliseClassProp(tag.props.class);
|
|
516
507
|
if (tag.props.content && Array.isArray(tag.props.content))
|
package/dist/index.mjs
CHANGED
|
@@ -498,17 +498,8 @@ async function normaliseTag(tagName, input, e) {
|
|
|
498
498
|
tag[k] = e[k];
|
|
499
499
|
}
|
|
500
500
|
});
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
try {
|
|
504
|
-
tag[k] = JSON.parse(tag[k]);
|
|
505
|
-
} catch (e2) {
|
|
506
|
-
tag[k] = "";
|
|
507
|
-
}
|
|
508
|
-
}
|
|
509
|
-
if (typeof tag[k] === "object")
|
|
510
|
-
tag[k] = JSON.stringify(tag[k]);
|
|
511
|
-
});
|
|
501
|
+
if (tag.tag === "script" && typeof tag.innerHTML === "object")
|
|
502
|
+
tag.innerHTML = JSON.stringify(tag.innerHTML);
|
|
512
503
|
if (tag.props.class)
|
|
513
504
|
tag.props.class = normaliseClassProp(tag.props.class);
|
|
514
505
|
if (tag.props.content && Array.isArray(tag.props.content))
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unhead/shared",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.3.
|
|
4
|
+
"version": "1.3.8",
|
|
5
5
|
"author": "Harlan Wilton <harlan@harlanzw.com>",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"funding": "https://github.com/sponsors/harlan-zw",
|
|
8
|
-
"homepage": "https://unhead.
|
|
8
|
+
"homepage": "https://unhead.unjs.io",
|
|
9
9
|
"repository": {
|
|
10
10
|
"type": "git",
|
|
11
11
|
"url": "git+https://github.com/unjs/unhead.git",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"dist"
|
|
35
35
|
],
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@unhead/schema": "1.3.
|
|
37
|
+
"@unhead/schema": "1.3.8"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"packrup": "^0.1.0"
|