mirror of
https://github.com/BradNut/personal-website-sveltekit
synced 2025-09-08 23:20:18 +00:00
Cleanup layout static SEO.
This commit is contained in:
parent
285336624a
commit
c9e16283e7
2 changed files with 13 additions and 10 deletions
|
|
@ -32,8 +32,18 @@
|
|||
titleTemplate: '%s | Bradley Shellnut',
|
||||
openGraph: {
|
||||
type: 'website',
|
||||
titleTemplate: '%s | Bradley Shellnut',
|
||||
locale: 'en_US',
|
||||
images: [
|
||||
{
|
||||
url: `${$page.data.baseUrl}b_shell_nut_favicon.gif`,
|
||||
alt: 'Bradley Shellnut Website Logo'
|
||||
}
|
||||
]
|
||||
},
|
||||
twitter: {
|
||||
card: 'summary_large_image',
|
||||
image: `${$page.data.baseUrl}b_shell_nut_favicon.gif`,
|
||||
imageAlt: 'Bradley Shellnut Website Logo'
|
||||
},
|
||||
...$page.data.metaTagsChild
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ import type { PageServerLoad } from './lib/$types';
|
|||
import { fetchBandcampAlbums } from '$root/lib/util/fetchBandcampAlbums';
|
||||
|
||||
export const load: PageServerLoad = async ({ fetch, setHeaders, url }) => {
|
||||
const baseUrl = new URL(url.origin).href;
|
||||
const metaTags: MetaTagsProps = Object.freeze({
|
||||
title: 'Home',
|
||||
description: "My name is Bradley Shellnut and I'm a Full Stack Software Engineer.",
|
||||
|
|
@ -11,19 +12,10 @@ export const load: PageServerLoad = async ({ fetch, setHeaders, url }) => {
|
|||
description: "My name is Bradley Shellnut and I'm a Full Stack Software Engineer.",
|
||||
url: new URL(url.pathname, url.origin).href,
|
||||
siteName: 'Bradley Shellnut Personal Website',
|
||||
images: [
|
||||
{
|
||||
url: `${new URL(url.origin).href}/b_shell_nut_favicon.gif`,
|
||||
alt: 'Bradley Shellnut Website Logo'
|
||||
}
|
||||
]
|
||||
},
|
||||
twitter: {
|
||||
card: 'summary_large_image',
|
||||
title: 'Home',
|
||||
description: 'Home page',
|
||||
images: `${new URL(url.origin).href}/b_shell_nut_favicon.gif`,
|
||||
imageAlt: 'Bradley Shellnut Website Logo'
|
||||
},
|
||||
url: new URL(url.pathname, url.origin).href
|
||||
});
|
||||
|
|
@ -35,6 +27,7 @@ export const load: PageServerLoad = async ({ fetch, setHeaders, url }) => {
|
|||
'cache-control': 'max-age=43200'
|
||||
});
|
||||
return {
|
||||
baseUrl,
|
||||
metaTagsChild: metaTags,
|
||||
albums: albums(),
|
||||
articlesData: (await articles()).json()
|
||||
|
|
|
|||
Loading…
Reference in a new issue