import React from 'react' import {SimpleLayout} from '@/components/layouts/SimpleLayout' import {Card} from '@/components/ui/Card' import {Views} from '@/components/ui/Views' import {formatDate} from '@/lib/formatDate' import {getAllArticles} from '@/lib/getAllArticles' import type {Article} from '@/types' const meta = { title: 'Writing - Ryan Freeman', heading: 'Writing on software engineering, and everything in between.', description: 'All of my long-form thoughts on software engineering, and more, displayed in chronological order.' } export const metadata = { ...meta, openGraph: { title: meta.title, description: meta.description, images: [ { url: `/api/og-image?text=${meta.heading}`, width: 1200, height: 600, alt: meta.heading, type: 'image/png' } ], type: 'website' } } function Article({article}: { article: Article }) { return (
{article.title}

{formatDate(article.date)}

) } export default async function Writing() { const articles = (await getAllArticles()).map(({component, ...meta}) => meta) return (
{articles.map((article) => (
))}
) }