fix(pages-blog): use date instead of pubDate

This commit is contained in:
xHyroM 2023-02-24 20:38:26 +01:00
parent 8906fda27a
commit 64057f3ae2

View file

@ -4,7 +4,7 @@ import Navbar from "../../components/widgets/Navbar.astro";
import Container from "../../components/atoms/Container.astro"; import Container from "../../components/atoms/Container.astro";
const posts = (await Astro.glob('./posts/*.md')).sort( const posts = (await Astro.glob('./posts/*.md')).sort(
(a, b) => new Date(b.frontmatter.pubDate).valueOf() - new Date(a.frontmatter.pubDate).valueOf() (a, b) => new Date(b.frontmatter.date).valueOf() - new Date(a.frontmatter.date).valueOf()
); );
--- ---