Basic solar network post preview

This commit is contained in:
2024-08-10 15:00:17 +08:00
parent bd76dc2ba8
commit c25640b673
9 changed files with 136 additions and 11 deletions

20
utils/seo.ts Normal file
View File

@ -0,0 +1,20 @@
export function createSEOHead(title: string, description: string, url: string) {
return [
{ key: "og:title", property: "og:title", content: title },
{
key: "og:description",
name: "og:description",
content: description,
},
{
key: "description",
name: "description",
content: description,
},
{
hid: 'og:url',
property: 'og:url',
content: useRuntimeConfig().public.baseUrl + '/' + url,
},
]
}