Compare commits
No commits in common. "dc6c24e56a1c14876cf3a0b3184575458d686b6f" and "97aa90a605602b9385ba734e2bd9d155aed954e8" have entirely different histories.
dc6c24e56a
...
97aa90a605
2
.env
2
.env
@ -1,2 +0,0 @@
|
|||||||
DEFAULT_TITLE=Valentin Popov’s Technology Blog
|
|
||||||
DEFAULT_DESCRIPTION=Tech insights and coding best practices from an OpenSource enthusiast and ethical hacker.
|
|
@ -14,7 +14,7 @@ const theme = "transparent_dark";
|
|||||||
---
|
---
|
||||||
|
|
||||||
<script
|
<script
|
||||||
is:inline
|
defer
|
||||||
src="https://giscus.app/client.js"
|
src="https://giscus.app/client.js"
|
||||||
data-category-id={categoryId}
|
data-category-id={categoryId}
|
||||||
data-category={category}
|
data-category={category}
|
||||||
@ -28,4 +28,5 @@ const theme = "transparent_dark";
|
|||||||
data-strict={strict}
|
data-strict={strict}
|
||||||
data-theme={theme}
|
data-theme={theme}
|
||||||
crossorigin={crossorigin}
|
crossorigin={crossorigin}
|
||||||
></script>
|
>
|
||||||
|
</script>
|
||||||
|
@ -1,20 +1,17 @@
|
|||||||
---
|
---
|
||||||
const canonicalURL = new URL(Astro.url.pathname, Astro.site);
|
const canonicalURL = new URL(Astro.url.pathname, Astro.site);
|
||||||
|
|
||||||
const { title, description } = Astro.props;
|
|
||||||
---
|
---
|
||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
<meta content="IE=edge" http-equiv="X-UA-Compatible" />
|
||||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
<meta content="text/html; charset=utf-8" http-equiv="content-type" />
|
||||||
|
<meta content="width=device-width, initial-scale=1" name="viewport" />
|
||||||
<meta name="description" content={description ?? import.meta.env.DEFAULT_DESCRIPTION} />
|
<meta content="index, follow" name="robots" />
|
||||||
<meta name="robots" content="index, follow" />
|
<meta content="Description" name="description" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
||||||
|
|
||||||
<link href="/feed.xml" rel="alternate" title="RSS" type="application/atom+xml" />
|
<link href="/feed.xml" rel="alternate" title="RSS" type="application/atom+xml" />
|
||||||
<link href="/sitemap-index.xml" rel="sitemap" />
|
<link href="/sitemap-index.xml" rel="sitemap" />
|
||||||
<link href={canonicalURL} rel="canonical" />
|
<link href={canonicalURL} rel="canonical" />
|
||||||
|
|
||||||
<title>{title ?? import.meta.env.DEFAULT_TITLE}</title>
|
<title>Title</title>
|
||||||
</head>
|
</head>
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
<header>
|
<header>
|
||||||
<nav>
|
<nav>
|
||||||
<a href="/">Home</a>
|
<a href="/">Home</a>
|
||||||
|
<a href="/blog/">Blog</a>
|
||||||
<span>
|
<span>
|
||||||
<span>|</span>
|
<span>|</span>
|
||||||
<a href="/feed.xml">RSS</a>
|
<a href="/feed.xml">RSS</a>
|
||||||
|
8
src/env.d.ts
vendored
8
src/env.d.ts
vendored
@ -1,9 +1 @@
|
|||||||
/// <reference path="../.astro/types.d.ts" />
|
/// <reference path="../.astro/types.d.ts" />
|
||||||
interface ImportMetaEnv {
|
|
||||||
readonly DEFAULT_TITLE: string;
|
|
||||||
readonly DEFAULT_DESCRIPTION: string;
|
|
||||||
}
|
|
||||||
|
|
||||||
interface ImportMeta {
|
|
||||||
readonly env: ImportMetaEnv;
|
|
||||||
}
|
|
||||||
|
@ -1,12 +1,10 @@
|
|||||||
---
|
---
|
||||||
import Head from "../components/Head.astro";
|
import Head from "../components/Head.astro";
|
||||||
import Header from "../components/Header.astro";
|
import Header from "../components/Header.astro";
|
||||||
|
|
||||||
const { title, description } = Astro.props;
|
|
||||||
---
|
---
|
||||||
|
|
||||||
<html lang="ru">
|
<html>
|
||||||
<Head title={title} description={description} />
|
<Head />
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
<Header />
|
<Header />
|
||||||
|
@ -1,9 +1,7 @@
|
|||||||
---
|
---
|
||||||
import BaseLayout from "./BaseLayout.astro";
|
import BaseLayout from "./BaseLayout.astro";
|
||||||
|
|
||||||
const { title, description } = Astro.props;
|
|
||||||
---
|
---
|
||||||
|
|
||||||
<BaseLayout title={title} description={description}>
|
<BaseLayout>
|
||||||
<slot />
|
<slot />
|
||||||
</BaseLayout>
|
</BaseLayout>
|
||||||
|
@ -22,7 +22,7 @@ const { Content, remarkPluginFrontmatter } = await post.render();
|
|||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<Layout title={post.data.title} description={post.data.description}>
|
<Layout>
|
||||||
<div class="header">
|
<div class="header">
|
||||||
<h1>{post.data.title}</h1>
|
<h1>{post.data.title}</h1>
|
||||||
<p>
|
<p>
|
||||||
|
@ -6,7 +6,7 @@ export async function GET(context) {
|
|||||||
|
|
||||||
return rss({
|
return rss({
|
||||||
customData: `<language>ru-ru</language>`,
|
customData: `<language>ru-ru</language>`,
|
||||||
description: import.meta.env.DEFAULT_DESCRIPTION,
|
description: "Tech insights and coding best practices from an OpenSource enthusiast and ethical hacker.",
|
||||||
items: posts.map((post) => ({
|
items: posts.map((post) => ({
|
||||||
customData: post.data.customData,
|
customData: post.data.customData,
|
||||||
description: post.data.description,
|
description: post.data.description,
|
||||||
@ -15,6 +15,6 @@ export async function GET(context) {
|
|||||||
title: post.data.title,
|
title: post.data.title,
|
||||||
})),
|
})),
|
||||||
site: context.site,
|
site: context.site,
|
||||||
title: import.meta.env.DEFAULT_TITLE,
|
title: "Valentin Popov’s Technology Blog",
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user