Files
iptvnator/apps/website/src/content.config.ts
T
4gray 69db46e122 chore(website): add reusable blog components including IconFeatureGrid, ImageGallery, LinkCards, PostButton, ReleaseMeta, Spoiler, StatusPill, StepRail, TerminalBlock
- Introduced new components for blog posts to enhance UI and functionality.
- Added support for featured posts and draft visibility in blog collections.
- Created demo blog post to showcase new components and their usage.
- Updated existing blog posts to utilize new components and improve content presentation.
2026-02-15 01:11:07 +01:00

20 lines
601 B
TypeScript

import { glob } from 'astro/loaders';
import { defineCollection, z } from 'astro:content';
const blog = defineCollection({
loader: glob({ pattern: '**/[^_]*.{md,mdx}', base: './src/content/blog' }),
schema: z.object({
title: z.string(),
description: z.string(),
pubDate: z.coerce.date(),
updatedDate: z.coerce.date().optional(),
author: z.string().default('4gray'),
featured: z.boolean().default(false),
heroImage: z.string().optional(),
tags: z.array(z.string()).default([]),
draft: z.boolean().default(false),
}),
});
export const collections = { blog };