mirror of
https://github.com/prdlk/prdlk.git
synced 2026-11-02 21:22:50 +00:00
1.1 KiB
1.1 KiB
data
Purpose
Thin query helpers over Content Collections — draft filtering, sorting, and the experience-taxonomy aggregation.
Key Files
| File | Description |
|---|---|
post.ts |
getAllPosts() (returns CollectionEntry<"writing">, drafts filtered in prod) and groupPostsByYear(). Naming quirk: file/functions say "post" but operate on the writing collection. |
experience.ts |
getAllExperience() (sorted by startDate desc) and getContentForExperience(id) which gathers all projects/writing/speaking entries whose experiences include id. |
speaking.ts |
getAllSpeaking() (drafts filtered in prod). |
For AI Agents
Working In This Directory
- Draft filtering uses
import.meta.env.PROD ? !data.draft : true— drafts are visible in dev, hidden in production. getContentForExperiencematches refs viaentry.data.experiences.some((ref) => ref.id === id).
Dependencies
Internal
astro:content(getCollection). Consumed by pages insrc/pages/and the homepage.