chore: set up SEO meta description (#1)
This commit is contained in:
parent
283b4557ed
commit
9e0009a6d8
2 changed files with 25 additions and 8 deletions
22
src/components/Head.astro
Normal file
22
src/components/Head.astro
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
---
|
||||||
|
export interface Props {
|
||||||
|
title: string;
|
||||||
|
}
|
||||||
|
const { title } = Astro.props;
|
||||||
|
const description =
|
||||||
|
"Ayo Ayco is a software engineer and consultant for hire, expecializing in web development | " +
|
||||||
|
title;
|
||||||
|
---
|
||||||
|
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8" />
|
||||||
|
<meta name="viewport" content="width=device-width" />
|
||||||
|
<meta name="generator" content={Astro.generator} />
|
||||||
|
<meta name="theme-color" content="#3054bf" />
|
||||||
|
|
||||||
|
<!-- SEO -->
|
||||||
|
<meta name="description" content={description} />
|
||||||
|
|
||||||
|
<link rel="shortcut icon" type="image/png" href="/favicon.ico" />
|
||||||
|
<title>{title}</title>
|
||||||
|
</head>
|
|
@ -1,4 +1,5 @@
|
||||||
---
|
---
|
||||||
|
import Head from "../components/Head.astro";
|
||||||
export interface Props {
|
export interface Props {
|
||||||
title: string;
|
title: string;
|
||||||
}
|
}
|
||||||
|
@ -8,14 +9,8 @@ const { title } = Astro.props;
|
||||||
|
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<Head title={title} />
|
||||||
<meta charset="UTF-8" />
|
|
||||||
<meta name="viewport" content="width=device-width" />
|
|
||||||
<meta name="generator" content={Astro.generator} />
|
|
||||||
<meta name="theme-color" content="#3054bf" />
|
|
||||||
<link rel="shortcut icon" type="image/png" href="/favicon.ico" />
|
|
||||||
<title>{title}</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
<body>
|
||||||
<slot />
|
<slot />
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue