From 9dbb2d05c929d4927e0c79654d8dfb462412759b Mon Sep 17 00:00:00 2001 From: Kamran Ahmed Date: Tue, 3 Jan 2023 20:43:25 +0400 Subject: [PATCH] Remove topic pages and upcoming roadmaps from index --- src/layouts/BaseLayout.astro | 3 +++ src/pages/[...topicId].astro | 2 +- src/pages/[roadmapId]/index.astro | 1 + 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/layouts/BaseLayout.astro b/src/layouts/BaseLayout.astro index b3abf36ae..741385607 100644 --- a/src/layouts/BaseLayout.astro +++ b/src/layouts/BaseLayout.astro @@ -12,6 +12,7 @@ export interface Props { title: string; description?: string; keywords?: string[]; + noIndex?: boolean; sponsor?: SponsorType; } @@ -19,6 +20,7 @@ const { title = siteConfig.title, description = siteConfig.description, keywords = siteConfig.keywords, + noIndex = false, sponsor, } = Astro.props; --- @@ -32,6 +34,7 @@ const { + {noIndex && } +
diff --git a/src/pages/[roadmapId]/index.astro b/src/pages/[roadmapId]/index.astro index 959140848..03b3f0d65 100644 --- a/src/pages/[roadmapId]/index.astro +++ b/src/pages/[roadmapId]/index.astro @@ -27,6 +27,7 @@ const roadmapData = roadmapFile.frontmatter as RoadmapFrontmatter; description={roadmapData.seo.description} keywords={roadmapData.seo.keywords} sponsor={roadmapData.sponsor} + noIndex={roadmapData.isUpcoming} >