@fy-/fws-vue 1.8.5 → 1.8.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.
Files changed (2) hide show
  1. package/composables/seo.ts +11 -4
  2. package/package.json +1 -1
@@ -1,3 +1,4 @@
1
+ // @ts-nocheck
1
2
  import type { Ref } from "vue";
2
3
  import { useHead } from "@unhead/vue";
3
4
  import { getURL, getLocale, getPrefix } from "@fy-/fws-js";
@@ -33,10 +34,11 @@ export const useSeo = (seo: Ref<LazyHead>, initial: boolean = false) => {
33
34
  useHead({
34
35
  title: () => seo.value.title || "",
35
36
  link: () => {
36
- const links = [];
37
+ const links: any[] = [];
37
38
 
38
39
  ["prev", "next"].forEach((rel) => {
39
40
  if (seo.value[rel as keyof LazyHead]) {
41
+ // @ts-ignore
40
42
  links.push({
41
43
  rel,
42
44
  href: seo.value[rel as keyof LazyHead] as string,
@@ -44,7 +46,7 @@ export const useSeo = (seo: Ref<LazyHead>, initial: boolean = false) => {
44
46
  });
45
47
  }
46
48
  });
47
-
49
+ // @ts-ignore
48
50
  links.push({
49
51
  rel: "canonical",
50
52
  href: `${url.Scheme}://${url.Host}${route.fullPath}`,
@@ -53,6 +55,7 @@ export const useSeo = (seo: Ref<LazyHead>, initial: boolean = false) => {
53
55
 
54
56
  seo.value.alternateLocales?.forEach((locale) => {
55
57
  if (locale !== currentLocale) {
58
+ // @ts-ignore
56
59
  links.push({
57
60
  rel: "alternate",
58
61
  hreflang: locale,
@@ -67,8 +70,8 @@ export const useSeo = (seo: Ref<LazyHead>, initial: boolean = false) => {
67
70
  return links;
68
71
  },
69
72
  meta: () => {
70
- const metas = [];
71
-
73
+ const metas: any[] = [];
74
+ // @ts-ignore
72
75
  metas.push(
73
76
  { property: "og:locale", content: currentLocale },
74
77
  {
@@ -92,6 +95,7 @@ export const useSeo = (seo: Ref<LazyHead>, initial: boolean = false) => {
92
95
  );
93
96
 
94
97
  if (seo.value.isAdult) {
98
+ // @ts-ignore
95
99
  metas.push(
96
100
  { name: "rating", content: "adult", key: "rating" },
97
101
  {
@@ -131,12 +135,14 @@ export const useSeo = (seo: Ref<LazyHead>, initial: boolean = false) => {
131
135
  property === "keywords" ||
132
136
  property.startsWith("twitter")
133
137
  ) {
138
+ // @ts-ignore
134
139
  metas.push({
135
140
  name: property,
136
141
  content: seoValue,
137
142
  key: property,
138
143
  });
139
144
  } else {
145
+ // @ts-ignore
140
146
  metas.push({
141
147
  property,
142
148
  content: seoValue as string,
@@ -148,6 +154,7 @@ export const useSeo = (seo: Ref<LazyHead>, initial: boolean = false) => {
148
154
  });
149
155
 
150
156
  if (seo.value.description) {
157
+ // @ts-ignore
151
158
  metas.push({
152
159
  name: "description",
153
160
  content: seo.value.description,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fy-/fws-vue",
3
- "version": "1.8.5",
3
+ "version": "1.8.7",
4
4
  "author": "Florian 'Fy' Gasquez <m@fy.to>",
5
5
  "license": "MIT",
6
6
  "repository": {