@unhead/vue 1.0.5 → 1.0.7
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 +3 -1
- package/dist/index.mjs +3 -1
- package/package.json +4 -4
package/dist/index.cjs
CHANGED
|
@@ -229,6 +229,8 @@ async function normaliseTag(tagName, input) {
|
|
|
229
229
|
["children", "innerHtml", "innerHTML"].forEach((key) => {
|
|
230
230
|
if (typeof tag.props[key] !== "undefined") {
|
|
231
231
|
tag.children = tag.props[key];
|
|
232
|
+
if (typeof tag.children === "object")
|
|
233
|
+
tag.children = JSON.stringify(tag.children);
|
|
232
234
|
delete tag.props[key];
|
|
233
235
|
}
|
|
234
236
|
});
|
|
@@ -790,7 +792,7 @@ const VueHeadMixin = {
|
|
|
790
792
|
const options = instance.type;
|
|
791
793
|
if (!options || !("head" in options))
|
|
792
794
|
return;
|
|
793
|
-
const source = typeof options.head === "function" ? () => options.head() : options.head;
|
|
795
|
+
const source = typeof options.head === "function" ? () => options.head.call(instance.proxy) : options.head;
|
|
794
796
|
useHead(source);
|
|
795
797
|
}
|
|
796
798
|
};
|
package/dist/index.mjs
CHANGED
|
@@ -227,6 +227,8 @@ async function normaliseTag(tagName, input) {
|
|
|
227
227
|
["children", "innerHtml", "innerHTML"].forEach((key) => {
|
|
228
228
|
if (typeof tag.props[key] !== "undefined") {
|
|
229
229
|
tag.children = tag.props[key];
|
|
230
|
+
if (typeof tag.children === "object")
|
|
231
|
+
tag.children = JSON.stringify(tag.children);
|
|
230
232
|
delete tag.props[key];
|
|
231
233
|
}
|
|
232
234
|
});
|
|
@@ -788,7 +790,7 @@ const VueHeadMixin = {
|
|
|
788
790
|
const options = instance.type;
|
|
789
791
|
if (!options || !("head" in options))
|
|
790
792
|
return;
|
|
791
|
-
const source = typeof options.head === "function" ? () => options.head() : options.head;
|
|
793
|
+
const source = typeof options.head === "function" ? () => options.head.call(instance.proxy) : options.head;
|
|
792
794
|
useHead(source);
|
|
793
795
|
}
|
|
794
796
|
};
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unhead/vue",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.0.
|
|
5
|
-
"packageManager": "pnpm@7.
|
|
4
|
+
"version": "1.0.7",
|
|
5
|
+
"packageManager": "pnpm@7.18.0",
|
|
6
6
|
"author": "Harlan Wilton <harlan@harlanzw.com>",
|
|
7
7
|
"license": "MIT",
|
|
8
8
|
"funding": "https://github.com/sponsors/harlan-zw",
|
|
@@ -34,11 +34,11 @@
|
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"hookable": "^5.4.2",
|
|
37
|
-
"@unhead/schema": "1.0.
|
|
37
|
+
"@unhead/schema": "1.0.7"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"vue": "^3.2.45",
|
|
41
|
-
"unhead": "1.0.
|
|
41
|
+
"unhead": "1.0.7"
|
|
42
42
|
},
|
|
43
43
|
"scripts": {
|
|
44
44
|
"build": "unbuild .",
|