From 39c2d60d538b7c7c642a82e6ef781b50d9fc6973 Mon Sep 17 00:00:00 2001 From: Aftab Alam <532906+one-aalam@users.noreply.github.com> Date: Tue, 31 Aug 2021 02:51:44 +0530 Subject: [PATCH] feat(2.6): Add common layout components --- src/layouts/default.astro | 32 ++++++++++++++++++++++++++++++++ src/pages/about.astro | 28 ++++------------------------ src/pages/index.astro | 16 +++++++--------- 3 files changed, 43 insertions(+), 33 deletions(-) create mode 100644 src/layouts/default.astro diff --git a/src/layouts/default.astro b/src/layouts/default.astro new file mode 100644 index 0000000..92fb122 --- /dev/null +++ b/src/layouts/default.astro @@ -0,0 +1,32 @@ +--- +import BaseHead from '../components/BaseHead.astro'; +import MainLayout from '../components/MainLayout.astro'; + +const { content, showPageHeader = true } = Astro.props +--- + + + + + + + {showPageHeader && + + } + + + + diff --git a/src/pages/about.astro b/src/pages/about.astro index 2ae311d..65c008b 100644 --- a/src/pages/about.astro +++ b/src/pages/about.astro @@ -1,19 +1,10 @@ --- -import BaseHead from '$/components/BaseHead.astro' -import MainLayout from '$/components/MainLayout.astro' +import DefaultPageLayout from '$/layouts/default.astro' + const title = 'About'; const description = 'There\'s a simple secret to building a faster website — just ship less.'; --- - - - - - - - +

Astro-Ink is a crisp, minimal, personal blog theme for Astro, that shows the capability of statically built sites - offering all the goodness and DX of the modern JS ecosystem without actually shipping any JS by default. It's built by... @@ -28,20 +19,9 @@ const description = 'There\'s a simple secret to building a faster website — j

- -
- +