---
import { getCollection } from "astro:content";
import ContentLayout from "@/layouts/content.astro";
import { ProjectList } from "@/components/projects/project-list";

const projects = (await getCollection("projects", ({ data }) => {
  return data.isDraft !== true;
})).sort(
  (a, b) => new Date(b.data.date).getTime() - new Date(a.data.date).getTime()
);
---

<ContentLayout 
  title="Projects | Timothy Pidashev"
  description="My portfolio of software, including web apps, dev tools, and passion projects."
>
  <ProjectList projects={projects} client:load />
</ContentLayout>
