From 14834024ec5ce30f521bee19f840208da0566ced Mon Sep 17 00:00:00 2001 From: Felix Schulze Date: Sat, 6 Dec 2025 15:20:23 +0100 Subject: [PATCH] FAQs --- src/app/components/FaqSection.tsx | 44 +++++++++++++++++++ .../learn/coast-fire-vs-lean-fire/page.tsx | 36 +++++++++++++++ .../page.tsx | 36 +++++++++++++++ src/app/learn/what-is-fire/page.tsx | 38 +++++++++++++++- 4 files changed, 153 insertions(+), 1 deletion(-) create mode 100644 src/app/components/FaqSection.tsx diff --git a/src/app/components/FaqSection.tsx b/src/app/components/FaqSection.tsx new file mode 100644 index 0000000..bf24794 --- /dev/null +++ b/src/app/components/FaqSection.tsx @@ -0,0 +1,44 @@ +import { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from '@/components/ui/accordion'; + +export interface FaqItem { + question: string; + answer: string; +} + +interface FaqSectionProps { + faqs: FaqItem[]; + className?: string; +} + +export function FaqSection({ faqs, className }: Readonly) { + // JSON-LD FAQPage schema + const jsonLd = { + '@context': 'https://schema.org', + '@type': 'FAQPage', + mainEntity: faqs.map((faq) => ({ + '@type': 'Question', + name: faq.question, + acceptedAnswer: { + '@type': 'Answer', + text: faq.answer, + }, + })), + }; + + return ( +
+