The documentation wasn’t much help, so I came here. I am trying to add metadata for my blog posts but I cannot figure out how to do that. This is my articles/[slug]/page.tsx code shortened:
'use client';
import { useEffect, useState } from 'react';
import dynamic from 'next/dynamic';
import fetchBlogPosts from '../../../../pages/api/get_content';
import ArticleHeader from '@/app/components/articleHeader';
import { firestore } from '../../../../firestore';
import { collection, addDoc, query, where, getDocs, Timestamp } from 'firebase/firestore';
import 'react-quill/dist/quill.snow.css';
const ReactQuill = dynamic(() => import('react-quill'), { ssr: false });
type BlogPost = {
title: string;
description: string;
image?: string | null;
content: string;
slug: string;
tags: Array<{ name: string }>;
};
const ArticlePage = ({ params, }: { params: { slug: string } }) => {
};
export default ArticlePage;
What do I need to do to have dynamic metadata?