Astro-based site with 40+ interactive math games, puzzles, and explorations. Includes admin dashboard, todo system, blog, theme/subcategory navigation, and embed pages for iframe embedding. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
22 lines
698 B
TypeScript
22 lines
698 B
TypeScript
import { defineCollection } from "astro:content";
|
|
import { glob } from "astro/loaders";
|
|
import { z } from "astro/zod";
|
|
|
|
const blog = defineCollection({
|
|
loader: glob({ pattern: "**/*.{md,mdx}", base: "src/content/blog" }),
|
|
schema: z.object({
|
|
title: z.string(),
|
|
tagline: z.string().optional(),
|
|
description: z.string().optional(),
|
|
author: z.string().optional(),
|
|
date: z.coerce.date().optional(),
|
|
published: z.coerce.date().optional(),
|
|
tags: z.array(z.string()).default([]),
|
|
coverImage: z.string().optional(),
|
|
image: z.string().optional(),
|
|
featured: z.boolean().optional(),
|
|
latest: z.boolean().optional(),
|
|
}),
|
|
});
|
|
|
|
export const collections = { blog };
|