chore: add some seo options and params

This commit is contained in:
Rick van Lieshout 2023-04-03 14:16:11 +02:00
parent 99d42b8de4
commit abc9cdbe26
6 changed files with 13 additions and 4 deletions

View File

@ -37,7 +37,7 @@
],
"author": {
"name": "Rick van Lieshout",
"photo": "/me.png",
"photo": "/content/me.png",
"bio": "I'm a passionate software architect that bifurcates his love between great software development and leading others to learn and adopt new things.",
"contacts": {
"email": "info@rickvanlieshout.com",

View File

@ -7,6 +7,7 @@ tags:
- "Lego"
- "house"
description: "What started as a simple decoration piece to fill some empty space in my home quickly grew into a new hobby of which the remnants can be found throughout my house"
socialImage: /media/building-the-owl.jpg
---
## The problem

View File

@ -1,7 +1,7 @@
import contacts from "./contacts";
export default {
photo: "/me.png",
photo: "/content/me.png",
bio: "",
name: "Rick van Lieshout",
contacts,

View File

@ -10,9 +10,16 @@ interface Props {
description?: string;
socialImage?: string;
children: React.ReactNode;
noIndex?: boolean;
}
const Layout: React.FC<Props> = ({ children, title, description, socialImage = "" }: Props) => {
const Layout: React.FC<Props> = ({
children,
title,
description,
socialImage = "",
noIndex = false,
}: Props) => {
const { author, url } = useSiteMetadata();
const metaImage = socialImage || author.photo;
const metaImageUrl = url + metaImage;
@ -29,6 +36,7 @@ const Layout: React.FC<Props> = ({ children, title, description, socialImage = "
<meta name="twitter:title" content={title} />
<meta name="twitter:description" content={description} />
<meta name="twitter:image" content={metaImageUrl} />
{noIndex && <meta name="robots" content="noindex" />}
</Helmet>
{children}
<CookieBar />

View File

@ -28,7 +28,7 @@ const TagTemplate: React.FC<Props> = ({ data, pageContext }: Props) => {
currentPage > 0 ? `${group} - Page ${currentPage} - ${siteTitle}` : `${group} - ${siteTitle}`;
return (
<Layout title={pageTitle} description={siteSubtitle}>
<Layout title={pageTitle} description={siteSubtitle} noIndex>
<Sidebar />
<Page title={group}>
<Feed edges={edges} />

BIN
static/content/me.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 49 KiB