0
mirror of https://github.com/valentineus/popov.link.git synced 2025-07-04 08:30:27 +03:00

Refactor Analytics and Head components

This commit is contained in:
2024-09-12 22:57:55 +00:00
parent b16d8ce36c
commit 33c9464dad
6 changed files with 33 additions and 18 deletions

View File

@ -9,17 +9,20 @@ type Props = {
readonly title?: string;
};
const { title, description } = Astro.props;
const { description, title } = Astro.props;
---
<html lang="ru">
<Head title={title} description={description} />
<Head
description={description ?? import.meta.env.DEFAULT_DESCRIPTION}
title={title ?? import.meta.env.DEFAULT_TITLE}
/>
<body>
<Header />
<main>
<slot />
</main>
<Analytics />
<Analytics title={title ?? import.meta.env.DEFAULT_TITLE} />
</body>
</html>