mirror of https://github.com/YunYouJun/valaxy
fix: meta og seo description
This commit is contained in:
parent
b7706990fd
commit
b8098c3837
|
@ -26,7 +26,7 @@ export function useValaxyApp() {
|
|||
// seo
|
||||
// todo: get first image url from markdown
|
||||
const siteUrl = computed(() => fm.value.url || siteConfig.value.url)
|
||||
const description = computed(() => $tO(fm.value.excerpt) || $tO(fm.value.description) || $tO(siteConfig.value.description))
|
||||
const description = computed(() => $tO(fm.value.excerpt) || $tO(fm.value.description) || $t(siteConfig.value.description))
|
||||
|
||||
useSeoMeta({
|
||||
description,
|
||||
|
@ -47,7 +47,7 @@ export function useValaxyApp() {
|
|||
definePerson({
|
||||
name: $t(siteConfig.value.author.name),
|
||||
url: siteUrl.value,
|
||||
image: siteConfig.value.author.avatar,
|
||||
image: $t(siteConfig.value.author.avatar),
|
||||
sameAs: siteConfig.value.social.map(s => s.link),
|
||||
}),
|
||||
defineWebSite({
|
||||
|
|
|
@ -16,7 +16,7 @@ export function useValaxyHead() {
|
|||
title: $title,
|
||||
titleTemplate: (title) => {
|
||||
const siteTitle = $t(siteConfig.value.title)
|
||||
return fm.value.titleTemplate || (title ? `${title} - ${siteTitle}` : siteTitle)
|
||||
return $tO(fm.value.titleTemplate) || (title ? `${title} - ${siteTitle}` : siteTitle)
|
||||
},
|
||||
link: [
|
||||
{
|
||||
|
@ -29,7 +29,7 @@ export function useValaxyHead() {
|
|||
computed(() => {
|
||||
return {
|
||||
name: 'description',
|
||||
content: fm.value.description || siteConfig.value.description,
|
||||
content: $tO(fm.value.description) || $t(siteConfig.value.description),
|
||||
}
|
||||
}),
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue