From 7437914e50714ac6ffb960b65fecf9adf04893a9 Mon Sep 17 00:00:00 2001 From: thomas Date: Fri, 13 Oct 2023 22:58:07 +0200 Subject: [PATCH] docs(comment section): add custom config --- docs/src/components/Content.astro | 4 +++- docs/src/content/config.ts | 10 ++++++++-- .../challenges/angular-performance/37-ngfor-biglist.md | 1 - .../docs/challenges/angular-performance/index.mdx | 1 + docs/src/content/docs/challenges/testing/index.mdx | 1 + docs/src/content/docs/index.mdx | 1 + 6 files changed, 14 insertions(+), 4 deletions(-) diff --git a/docs/src/components/Content.astro b/docs/src/components/Content.astro index 05c66ee..0bfc0fe 100644 --- a/docs/src/components/Content.astro +++ b/docs/src/components/Content.astro @@ -3,7 +3,7 @@ import type { Props } from '@astrojs/starlight/props'; import Default from '@astrojs/starlight/components/MarkdownContent.astro'; const slug = Astro.props.slug; -const renderCommentSection = !(['', 'challenges/testing', 'challenges/angular-performance']).includes(slug) +const renderCommentSection = !Astro.props.entry.data.noCommentSection; --- @@ -12,6 +12,8 @@ const renderCommentSection = !(['', 'challenges/testing', 'challenges/angular-pe
+{Astro.props.entry.data.custom} + { renderCommentSection ?