@unhead/vue 1.11.14 → 1.11.15
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/components.cjs +1 -1
- package/dist/components.mjs +1 -1
- package/dist/index.cjs +2 -2
- package/dist/index.d.cts +2 -2
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.mjs +3 -3
- package/dist/polyfill.cjs +2 -2
- package/dist/polyfill.d.cts +1 -1
- package/dist/polyfill.d.mts +1 -1
- package/dist/polyfill.d.ts +1 -1
- package/dist/polyfill.mjs +2 -2
- package/dist/shared/{vue.8fc199ce.mjs → vue.-sixQ7xP.mjs} +1 -1
- package/dist/shared/{vue.104c41b5.cjs → vue.BmMjB48i.cjs} +1 -1
- package/dist/vue2.cjs +13 -28
- package/dist/vue2.mjs +13 -28
- package/package.json +4 -5
- /package/dist/shared/{vue.6b1572ee.cjs → vue.DWlmwWrc.cjs} +0 -0
- /package/dist/shared/{vue.71760da0.d.cts → vue.fwis0K4Q.d.cts} +0 -0
- /package/dist/shared/{vue.71760da0.d.mts → vue.fwis0K4Q.d.mts} +0 -0
- /package/dist/shared/{vue.71760da0.d.ts → vue.fwis0K4Q.d.ts} +0 -0
- /package/dist/shared/{vue.f49591ad.mjs → vue.ziyDaVMR.mjs} +0 -0
package/dist/components.cjs
CHANGED
package/dist/components.mjs
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
const unhead = require('unhead');
|
|
4
|
-
const injectHead = require('./shared/vue.
|
|
4
|
+
const injectHead = require('./shared/vue.DWlmwWrc.cjs');
|
|
5
5
|
const shared = require('@unhead/shared');
|
|
6
|
-
const useHead = require('./shared/vue.
|
|
6
|
+
const useHead = require('./shared/vue.BmMjB48i.cjs');
|
|
7
7
|
const vue = require('vue');
|
|
8
8
|
|
|
9
9
|
const coreComposableNames = [
|
package/dist/index.d.cts
CHANGED
|
@@ -2,8 +2,8 @@ export { CapoPlugin, HashHydrationPlugin, createHeadCore } from 'unhead';
|
|
|
2
2
|
import * as _unhead_schema from '@unhead/schema';
|
|
3
3
|
import { SafeMeta, SafeLink, SafeNoscript, SafeScript, SafeHtmlAttr, SafeBodyAttr, MergeHead, CreateHeadOptions, ActiveHeadEntry, ScriptInstance, UseScriptStatus, ScriptBase, DataKeys, SchemaAugmentations, HeadEntryOptions, UseScriptOptions as UseScriptOptions$1, AsAsyncFunctionValues, UseFunctionType } from '@unhead/schema';
|
|
4
4
|
export { ActiveHeadEntry, Head, HeadEntryOptions, HeadTag, MergeHead, Unhead } from '@unhead/schema';
|
|
5
|
-
import { R as ReactiveHead, M as MaybeComputedRefEntries, a as MaybeComputedRef, V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions, c as MaybeComputedRefEntriesOnly, d as UseSeoMetaInput } from './shared/vue.
|
|
6
|
-
export { f as Base, B as BodyAttr, j as BodyAttributes, H as HtmlAttr, i as HtmlAttributes, L as Link, l as MaybeComputedRefOrFalsy, m as MaybeComputedRefOrPromise, k as MaybeReadonlyRef, g as Meta, N as Noscript, h as Script, S as Style, T as Title, e as TitleTemplate } from './shared/vue.
|
|
5
|
+
import { R as ReactiveHead, M as MaybeComputedRefEntries, a as MaybeComputedRef, V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions, c as MaybeComputedRefEntriesOnly, d as UseSeoMetaInput } from './shared/vue.fwis0K4Q.cjs';
|
|
6
|
+
export { f as Base, B as BodyAttr, j as BodyAttributes, H as HtmlAttr, i as HtmlAttributes, L as Link, l as MaybeComputedRefOrFalsy, m as MaybeComputedRefOrPromise, k as MaybeReadonlyRef, g as Meta, N as Noscript, h as Script, S as Style, T as Title, e as TitleTemplate } from './shared/vue.fwis0K4Q.cjs';
|
|
7
7
|
import { Ref, Plugin } from 'vue';
|
|
8
8
|
|
|
9
9
|
interface HeadSafe extends Pick<ReactiveHead, 'title' | 'titleTemplate' | 'templateParams'> {
|
package/dist/index.d.mts
CHANGED
|
@@ -2,8 +2,8 @@ export { CapoPlugin, HashHydrationPlugin, createHeadCore } from 'unhead';
|
|
|
2
2
|
import * as _unhead_schema from '@unhead/schema';
|
|
3
3
|
import { SafeMeta, SafeLink, SafeNoscript, SafeScript, SafeHtmlAttr, SafeBodyAttr, MergeHead, CreateHeadOptions, ActiveHeadEntry, ScriptInstance, UseScriptStatus, ScriptBase, DataKeys, SchemaAugmentations, HeadEntryOptions, UseScriptOptions as UseScriptOptions$1, AsAsyncFunctionValues, UseFunctionType } from '@unhead/schema';
|
|
4
4
|
export { ActiveHeadEntry, Head, HeadEntryOptions, HeadTag, MergeHead, Unhead } from '@unhead/schema';
|
|
5
|
-
import { R as ReactiveHead, M as MaybeComputedRefEntries, a as MaybeComputedRef, V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions, c as MaybeComputedRefEntriesOnly, d as UseSeoMetaInput } from './shared/vue.
|
|
6
|
-
export { f as Base, B as BodyAttr, j as BodyAttributes, H as HtmlAttr, i as HtmlAttributes, L as Link, l as MaybeComputedRefOrFalsy, m as MaybeComputedRefOrPromise, k as MaybeReadonlyRef, g as Meta, N as Noscript, h as Script, S as Style, T as Title, e as TitleTemplate } from './shared/vue.
|
|
5
|
+
import { R as ReactiveHead, M as MaybeComputedRefEntries, a as MaybeComputedRef, V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions, c as MaybeComputedRefEntriesOnly, d as UseSeoMetaInput } from './shared/vue.fwis0K4Q.mjs';
|
|
6
|
+
export { f as Base, B as BodyAttr, j as BodyAttributes, H as HtmlAttr, i as HtmlAttributes, L as Link, l as MaybeComputedRefOrFalsy, m as MaybeComputedRefOrPromise, k as MaybeReadonlyRef, g as Meta, N as Noscript, h as Script, S as Style, T as Title, e as TitleTemplate } from './shared/vue.fwis0K4Q.mjs';
|
|
7
7
|
import { Ref, Plugin } from 'vue';
|
|
8
8
|
|
|
9
9
|
interface HeadSafe extends Pick<ReactiveHead, 'title' | 'titleTemplate' | 'templateParams'> {
|
package/dist/index.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ export { CapoPlugin, HashHydrationPlugin, createHeadCore } from 'unhead';
|
|
|
2
2
|
import * as _unhead_schema from '@unhead/schema';
|
|
3
3
|
import { SafeMeta, SafeLink, SafeNoscript, SafeScript, SafeHtmlAttr, SafeBodyAttr, MergeHead, CreateHeadOptions, ActiveHeadEntry, ScriptInstance, UseScriptStatus, ScriptBase, DataKeys, SchemaAugmentations, HeadEntryOptions, UseScriptOptions as UseScriptOptions$1, AsAsyncFunctionValues, UseFunctionType } from '@unhead/schema';
|
|
4
4
|
export { ActiveHeadEntry, Head, HeadEntryOptions, HeadTag, MergeHead, Unhead } from '@unhead/schema';
|
|
5
|
-
import { R as ReactiveHead, M as MaybeComputedRefEntries, a as MaybeComputedRef, V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions, c as MaybeComputedRefEntriesOnly, d as UseSeoMetaInput } from './shared/vue.
|
|
6
|
-
export { f as Base, B as BodyAttr, j as BodyAttributes, H as HtmlAttr, i as HtmlAttributes, L as Link, l as MaybeComputedRefOrFalsy, m as MaybeComputedRefOrPromise, k as MaybeReadonlyRef, g as Meta, N as Noscript, h as Script, S as Style, T as Title, e as TitleTemplate } from './shared/vue.
|
|
5
|
+
import { R as ReactiveHead, M as MaybeComputedRefEntries, a as MaybeComputedRef, V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions, c as MaybeComputedRefEntriesOnly, d as UseSeoMetaInput } from './shared/vue.fwis0K4Q.js';
|
|
6
|
+
export { f as Base, B as BodyAttr, j as BodyAttributes, H as HtmlAttr, i as HtmlAttributes, L as Link, l as MaybeComputedRefOrFalsy, m as MaybeComputedRefOrPromise, k as MaybeReadonlyRef, g as Meta, N as Noscript, h as Script, S as Style, T as Title, e as TitleTemplate } from './shared/vue.fwis0K4Q.js';
|
|
7
7
|
import { Ref, Plugin } from 'vue';
|
|
8
8
|
|
|
9
9
|
interface HeadSafe extends Pick<ReactiveHead, 'title' | 'titleTemplate' | 'templateParams'> {
|
package/dist/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { useScript as useScript$1 } from 'unhead';
|
|
2
2
|
export { CapoPlugin, HashHydrationPlugin, createHeadCore } from 'unhead';
|
|
3
|
-
import { i as injectHead, h as headSymbol, V as Vue3 } from './shared/vue.
|
|
4
|
-
export { c as createHead, a as createServerHead, r as resolveUnrefHeadInput, s as setHeadInjectionHandler } from './shared/vue.
|
|
3
|
+
import { i as injectHead, h as headSymbol, V as Vue3 } from './shared/vue.ziyDaVMR.mjs';
|
|
4
|
+
export { c as createHead, a as createServerHead, r as resolveUnrefHeadInput, s as setHeadInjectionHandler } from './shared/vue.ziyDaVMR.mjs';
|
|
5
5
|
import { composableNames, whitelistSafeInput, unpackMeta } from '@unhead/shared';
|
|
6
|
-
import { u as useHead } from './shared/vue.
|
|
6
|
+
import { u as useHead } from './shared/vue.-sixQ7xP.mjs';
|
|
7
7
|
import { getCurrentInstance, onMounted, isRef, watch, onScopeDispose, ref } from 'vue';
|
|
8
8
|
|
|
9
9
|
const coreComposableNames = [
|
package/dist/polyfill.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const useHead = require('./shared/vue.
|
|
3
|
+
const useHead = require('./shared/vue.BmMjB48i.cjs');
|
|
4
4
|
require('vue');
|
|
5
|
-
require('./shared/vue.
|
|
5
|
+
require('./shared/vue.DWlmwWrc.cjs');
|
|
6
6
|
require('unhead');
|
|
7
7
|
require('@unhead/shared');
|
|
8
8
|
|
package/dist/polyfill.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MergeHead } from '@unhead/schema';
|
|
2
|
-
import { V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions } from './shared/vue.
|
|
2
|
+
import { V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions } from './shared/vue.fwis0K4Q.cjs';
|
|
3
3
|
import 'vue';
|
|
4
4
|
|
|
5
5
|
type VueHeadClientPollyFill<T extends MergeHead> = VueHeadClient<T> & {
|
package/dist/polyfill.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MergeHead } from '@unhead/schema';
|
|
2
|
-
import { V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions } from './shared/vue.
|
|
2
|
+
import { V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions } from './shared/vue.fwis0K4Q.mjs';
|
|
3
3
|
import 'vue';
|
|
4
4
|
|
|
5
5
|
type VueHeadClientPollyFill<T extends MergeHead> = VueHeadClient<T> & {
|
package/dist/polyfill.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { MergeHead } from '@unhead/schema';
|
|
2
|
-
import { V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions } from './shared/vue.
|
|
2
|
+
import { V as VueHeadClient, U as UseHeadInput, b as UseHeadOptions } from './shared/vue.fwis0K4Q.js';
|
|
3
3
|
import 'vue';
|
|
4
4
|
|
|
5
5
|
type VueHeadClientPollyFill<T extends MergeHead> = VueHeadClient<T> & {
|
package/dist/polyfill.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ref, watchEffect, watch, getCurrentInstance, onBeforeUnmount, onDeactivated, onActivated } from 'vue';
|
|
2
|
-
import { i as injectHead, r as resolveUnrefHeadInput } from './vue.
|
|
2
|
+
import { i as injectHead, r as resolveUnrefHeadInput } from './vue.ziyDaVMR.mjs';
|
|
3
3
|
|
|
4
4
|
function useHead(input, options = {}) {
|
|
5
5
|
const head = options.head || injectHead();
|
package/dist/vue2.cjs
CHANGED
|
@@ -1,42 +1,27 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
const injectHead = require('./shared/vue.6b1572ee.cjs');
|
|
3
|
+
const useHead = require('./shared/vue.BmMjB48i.cjs');
|
|
4
|
+
const injectHead = require('./shared/vue.DWlmwWrc.cjs');
|
|
5
|
+
require('vue');
|
|
7
6
|
require('unhead');
|
|
8
7
|
require('@unhead/shared');
|
|
9
8
|
|
|
10
9
|
const UnheadPlugin = (_Vue) => {
|
|
11
|
-
_Vue.config.optionMergeStrategies.head = function(toVal, fromVal
|
|
12
|
-
|
|
13
|
-
toVal = toVal.call(vm || this || _Vue);
|
|
14
|
-
}
|
|
15
|
-
if (typeof fromVal === "function") {
|
|
16
|
-
fromVal = fromVal.call(vm || this || _Vue);
|
|
17
|
-
}
|
|
18
|
-
return defu.defu(toVal, fromVal);
|
|
10
|
+
_Vue.config.optionMergeStrategies.head = function(toVal, fromVal) {
|
|
11
|
+
return [toVal, fromVal].flat().filter(Boolean);
|
|
19
12
|
};
|
|
20
13
|
_Vue.mixin({
|
|
21
14
|
created() {
|
|
22
|
-
|
|
23
|
-
if (
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
source = typeof options.head === "function" ? () => options.head.call(instance.proxy) : options.head;
|
|
31
|
-
} else {
|
|
32
|
-
const head = this.$options.head;
|
|
33
|
-
if (head) {
|
|
34
|
-
source = typeof head === "function" ? () => head.call(this) : head;
|
|
15
|
+
const head = this.$options.head;
|
|
16
|
+
if (head) {
|
|
17
|
+
if (Array.isArray(head)) {
|
|
18
|
+
head.forEach((h) => {
|
|
19
|
+
useHead.useHead(typeof h === "function" ? h.call(this) : h);
|
|
20
|
+
});
|
|
21
|
+
} else {
|
|
22
|
+
useHead.useHead(typeof head === "function" ? head.call(this) : head);
|
|
35
23
|
}
|
|
36
24
|
}
|
|
37
|
-
if (source) {
|
|
38
|
-
useHead.useHead(source);
|
|
39
|
-
}
|
|
40
25
|
},
|
|
41
26
|
beforeCreate() {
|
|
42
27
|
const options = this.$options;
|
package/dist/vue2.mjs
CHANGED
|
@@ -1,40 +1,25 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import { V as Vue3, h as headSymbol } from './shared/vue.f49591ad.mjs';
|
|
1
|
+
import { u as useHead } from './shared/vue.-sixQ7xP.mjs';
|
|
2
|
+
import { h as headSymbol } from './shared/vue.ziyDaVMR.mjs';
|
|
3
|
+
import 'vue';
|
|
5
4
|
import 'unhead';
|
|
6
5
|
import '@unhead/shared';
|
|
7
6
|
|
|
8
7
|
const UnheadPlugin = (_Vue) => {
|
|
9
|
-
_Vue.config.optionMergeStrategies.head = function(toVal, fromVal
|
|
10
|
-
|
|
11
|
-
toVal = toVal.call(vm || this || _Vue);
|
|
12
|
-
}
|
|
13
|
-
if (typeof fromVal === "function") {
|
|
14
|
-
fromVal = fromVal.call(vm || this || _Vue);
|
|
15
|
-
}
|
|
16
|
-
return defu(toVal, fromVal);
|
|
8
|
+
_Vue.config.optionMergeStrategies.head = function(toVal, fromVal) {
|
|
9
|
+
return [toVal, fromVal].flat().filter(Boolean);
|
|
17
10
|
};
|
|
18
11
|
_Vue.mixin({
|
|
19
12
|
created() {
|
|
20
|
-
|
|
21
|
-
if (
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
source = typeof options.head === "function" ? () => options.head.call(instance.proxy) : options.head;
|
|
29
|
-
} else {
|
|
30
|
-
const head = this.$options.head;
|
|
31
|
-
if (head) {
|
|
32
|
-
source = typeof head === "function" ? () => head.call(this) : head;
|
|
13
|
+
const head = this.$options.head;
|
|
14
|
+
if (head) {
|
|
15
|
+
if (Array.isArray(head)) {
|
|
16
|
+
head.forEach((h) => {
|
|
17
|
+
useHead(typeof h === "function" ? h.call(this) : h);
|
|
18
|
+
});
|
|
19
|
+
} else {
|
|
20
|
+
useHead(typeof head === "function" ? head.call(this) : head);
|
|
33
21
|
}
|
|
34
22
|
}
|
|
35
|
-
if (source) {
|
|
36
|
-
useHead(source);
|
|
37
|
-
}
|
|
38
23
|
},
|
|
39
24
|
beforeCreate() {
|
|
40
25
|
const options = this.$options;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@unhead/vue",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.11.
|
|
4
|
+
"version": "1.11.15",
|
|
5
5
|
"author": "Harlan Wilton <harlan@harlanzw.com>",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"funding": "https://github.com/sponsors/harlan-zw",
|
|
@@ -65,11 +65,10 @@
|
|
|
65
65
|
]
|
|
66
66
|
},
|
|
67
67
|
"dependencies": {
|
|
68
|
-
"defu": "^6.1.4",
|
|
69
68
|
"hookable": "^5.5.3",
|
|
70
|
-
"@unhead/
|
|
71
|
-
"
|
|
72
|
-
"unhead": "1.11.
|
|
69
|
+
"@unhead/schema": "1.11.15",
|
|
70
|
+
"unhead": "1.11.15",
|
|
71
|
+
"@unhead/shared": "1.11.15"
|
|
73
72
|
},
|
|
74
73
|
"scripts": {
|
|
75
74
|
"build": "unbuild .",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|