diff --git a/apps/site/src/pages/blog/index.astro b/apps/site/src/pages/blog/index.astro
index 6170552..c6e299c 100644
--- a/apps/site/src/pages/blog/index.astro
+++ b/apps/site/src/pages/blog/index.astro
@@ -1,11 +1,15 @@
---
-import { getCollection } from 'astro:content';
-import ArticleCard from '~/components/ArticleCard.astro';
-import Layout from '~/layouts/Layout.astro';
+import { getCollection } from "astro:content";
+import ArticleCard from "~/components/ArticleCard.astro";
+import Layout from "~/layouts/Layout.astro";
-const title = 'Articles';
-const articles = await getCollection('blog', ({ data }) => {
- return import.meta.env.PROD ? data.draft !== true : true;
+const title = "Articles";
+const sortedArticles = (
+ await getCollection("blog", ({ data }) => {
+ return import.meta.env.PROD ? data.draft !== true : true;
+ })
+).sort((a, b) => {
+ return b.data.publishDate.getTime() - a.data.publishDate.getTime();
});
---
@@ -16,8 +20,8 @@ const articles = await getCollection('blog', ({ data }) => {
>
{title}
-
- {articles.map((article) =>
)}
+
+ {sortedArticles.map((article) =>
)}
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 5f880f9..f617c4c 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -16,7 +16,7 @@ importers:
version: 1.26.7
'@types/github-script':
specifier: github:actions/github-script
- version: github-script@https://codeload.github.com/actions/github-script/tar.gz/35b1cdd1b2c1fc704b1cd9758d10f67e833fcb02
+ version: github-script@https://codeload.github.com/actions/github-script/tar.gz/660ec11d825b714d112a6bb9727086bc2cc500b2
'@types/node':
specifier: 20.14.12
version: 20.14.12
@@ -133,9 +133,6 @@ packages:
peerDependencies:
astro: ^4.10.3
- '@astrojs/compiler@2.8.0':
- resolution: {integrity: sha512-yrpD1WRGqsJwANaDIdtHo+YVjvIOFAjC83lu5qENIgrafwZcJgSXDuwVMXOgok4tFzpeKLsFQ6c3FoUdloLWBQ==}
-
'@astrojs/compiler@2.9.1':
resolution: {integrity: sha512-s8Ge2lWHx/s3kl4UoerjL/iPtwdtogNM/BLOaGCwQA6crMOVYpphy5wUkYlKyuh8GAeGYH/5haLAFBsgNy9AQQ==}
@@ -1463,11 +1460,6 @@ packages:
resolution: {integrity: sha512-cjkyv4OtNCIeqhHrfS81QWXoCBPExR/J62oyEqepVw8WaQeSqpW2uhuLPh1m9eWhDuOo/jUXVTlifvesOWp/4A==}
engines: {node: '>=0.4.0'}
- acorn@8.11.3:
- resolution: {integrity: sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==}
- engines: {node: '>=0.4.0'}
- hasBin: true
-
acorn@8.12.1:
resolution: {integrity: sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg==}
engines: {node: '>=0.4.0'}
@@ -1607,11 +1599,6 @@ packages:
resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==}
engines: {node: '>=8'}
- browserslist@4.23.0:
- resolution: {integrity: sha512-QW8HiM1shhT2GuzkvklfjcKDiWFXHOeFCIA/huJPwHsslwcydgk7X+z2zXpEijP98UCY7HbubZt5J2Zgvf0CaQ==}
- engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7}
- hasBin: true
-
browserslist@4.23.2:
resolution: {integrity: sha512-qkqSyistMYdxAcw+CzbZwlBy8AGmS/eEWs+sEV5TnLRGDOL+C5M2EnH6tlZyg0YoAxGJAFKh61En9BR941GnHA==}
engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7}
@@ -1632,9 +1619,6 @@ packages:
resolution: {integrity: sha512-8WB3Jcas3swSvjIeA2yvCJ+Miyz5l1ZmB6HFb9R1317dt9LCQoswg/BGrmAmkWVEszSrrg4RwmO46qIm2OEnSA==}
engines: {node: '>=16'}
- caniuse-lite@1.0.30001627:
- resolution: {integrity: sha512-4zgNiB8nTyV/tHhwZrFs88ryjls/lHiqFhrxCW4qSTeuRByBVnPYpDInchOIySWknznucaf31Z4KYqjfbrecVw==}
-
caniuse-lite@1.0.30001642:
resolution: {integrity: sha512-3XQ0DoRgLijXJErLSl+bLnJ+Et4KqV1PY6JJBGAFlsNsz31zeAIncyeZfLCabHK/jtSh+671RM9YMldxjUPZtA==}
@@ -1978,9 +1962,6 @@ packages:
eastasianwidth@0.2.0:
resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==}
- electron-to-chromium@1.4.788:
- resolution: {integrity: sha512-ubp5+Ev/VV8KuRoWnfP2QF2Bg+O2ZFdb49DiiNbz2VmgkIqrnyYaqIOqj8A6K/3p1xV0QcU5hBQ1+BmB6ot1OA==}
-
electron-to-chromium@1.4.829:
resolution: {integrity: sha512-5qp1N2POAfW0u1qGAxXEtz6P7bO1m6gpZr5hdf5ve6lxpLM7MpiM4jIPz7xcrNlClQMafbyUDDWjlIQZ1Mw0Rw==}
@@ -2184,8 +2165,8 @@ packages:
resolution: {integrity: sha512-VaUJspBffn/LMCJVoMvSAdmscJyS1auj5Zulnn5UoYcY531UWmdwhRWkcGKnGU93m5HSXP9LP2usOryrBtQowA==}
engines: {node: '>=16'}
- github-script@https://codeload.github.com/actions/github-script/tar.gz/35b1cdd1b2c1fc704b1cd9758d10f67e833fcb02:
- resolution: {tarball: https://codeload.github.com/actions/github-script/tar.gz/35b1cdd1b2c1fc704b1cd9758d10f67e833fcb02}
+ github-script@https://codeload.github.com/actions/github-script/tar.gz/660ec11d825b714d112a6bb9727086bc2cc500b2:
+ resolution: {tarball: https://codeload.github.com/actions/github-script/tar.gz/660ec11d825b714d112a6bb9727086bc2cc500b2}
version: 7.0.1
engines: {node: '>=20.0.0 <21.0.0'}
@@ -3025,10 +3006,6 @@ packages:
postcss-value-parser@4.2.0:
resolution: {integrity: sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==}
- postcss@8.4.38:
- resolution: {integrity: sha512-Wglpdk03BSfXkHoQa3b/oulrotAkwrlLDRSOb9D0bN86FdRyE9lppSp33aHNPgBa0JKCoB+drFLZkQoRRYae5A==}
- engines: {node: ^10 || ^12 || >=14}
-
postcss@8.4.39:
resolution: {integrity: sha512-0vzE+lAiG7hZl1/9I8yzKLx3aR9Xbof3fBHKunvMfOCYAtMhrsnccJY2iTURb9EZd5+pLuiNV9/c/GZJOHsgIw==}
engines: {node: ^10 || ^12 || >=14}
@@ -3104,10 +3081,6 @@ packages:
remark-rehype@11.1.0:
resolution: {integrity: sha512-z3tJrAs2kIs1AqIIy6pzHmAHlF1hWQ+OdY4/hv+Wxe35EhyLKcajL33iUEn3ScxtFox9nUvRufR/Zre8Q08H/g==}
- remark-smartypants@3.0.1:
- resolution: {integrity: sha512-qyshfCl2eLO0i0558e79ZJsfojC5wjnYLByjt0FmjJQN6aYwcRxpoj784LZJSoWCdnA2ubh5rLNGb8Uur/wDng==}
- engines: {node: '>=16.0.0'}
-
remark-smartypants@3.0.2:
resolution: {integrity: sha512-ILTWeOriIluwEvPjv67v7Blgrcx+LZOkAUVtKI3putuhlZm84FnqDORNXPPm+HY3NdZOMhyDwZ1E+eZB/Df5dA==}
engines: {node: '>=16.0.0'}
@@ -3279,10 +3252,6 @@ packages:
resolution: {integrity: sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==}
engines: {node: '>=12'}
- string-width@7.1.0:
- resolution: {integrity: sha512-SEIJCWiX7Kg4c129n48aDRwLbFb2LJmXXFrWBG4NGaRtMQ3myKPKbwrD1BKqQn74oCoNMBVrfDEr5M9YxCsrkw==}
- engines: {node: '>=18'}
-
string-width@7.2.0:
resolution: {integrity: sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==}
engines: {node: '>=18'}
@@ -3462,12 +3431,6 @@ packages:
resolution: {integrity: sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==}
engines: {node: '>= 10.0.0'}
- update-browserslist-db@1.0.16:
- resolution: {integrity: sha512-KVbTxlBYlckhF5wgfyZXTWnMn7MMZjMu9XG8bPlliUOP9ThaF4QnhP8qrjrH7DRzHfSk0oQv1wToW+iA5GajEQ==}
- hasBin: true
- peerDependencies:
- browserslist: '>= 4.21.0'
-
update-browserslist-db@1.1.0:
resolution: {integrity: sha512-EdRAaAyk2cUE1wOf2DkEhzxqOQvFOoRJFNS6NeyJ01Gp2beMRpBAINjM2iDXE3KCuKhwnvHIQCJm6ThL2Z+HzQ==}
hasBin: true
@@ -3800,8 +3763,6 @@ snapshots:
- supports-color
- utf-8-validate
- '@astrojs/compiler@2.8.0': {}
-
'@astrojs/compiler@2.9.1': {}
'@astrojs/db@0.11.7(@cloudflare/workers-types@4.20240729.0)':
@@ -3854,7 +3815,7 @@ snapshots:
'@astrojs/language-server@2.10.0(typescript@5.4.5)':
dependencies:
- '@astrojs/compiler': 2.8.0
+ '@astrojs/compiler': 2.9.1
'@jridgewell/sourcemap-codec': 1.4.15
'@volar/kit': 2.2.5(typescript@5.4.5)
'@volar/language-core': 2.2.5
@@ -3886,7 +3847,7 @@ snapshots:
remark-gfm: 4.0.0
remark-parse: 11.0.0
remark-rehype: 11.1.0
- remark-smartypants: 3.0.1
+ remark-smartypants: 3.0.2
shiki: 1.10.3
unified: 11.0.5
unist-util-remove-position: 5.0.0
@@ -3992,9 +3953,9 @@ snapshots:
'@astrojs/tailwind@5.1.0(astro@4.11.6(@types/node@20.14.12)(typescript@5.4.5))(tailwindcss@3.4.7)':
dependencies:
astro: 4.11.6(@types/node@20.14.12)(typescript@5.4.5)
- autoprefixer: 10.4.19(postcss@8.4.38)
- postcss: 8.4.38
- postcss-load-config: 4.0.2(postcss@8.4.38)
+ autoprefixer: 10.4.19(postcss@8.4.39)
+ postcss: 8.4.39
+ postcss-load-config: 4.0.2(postcss@8.4.39)
tailwindcss: 3.4.7
transitivePeerDependencies:
- ts-node
@@ -5119,8 +5080,6 @@ snapshots:
acorn-walk@8.3.2: {}
- acorn@8.11.3: {}
-
acorn@8.12.1: {}
ansi-align@3.0.1:
@@ -5270,14 +5229,14 @@ snapshots:
async-listen@3.0.1: {}
- autoprefixer@10.4.19(postcss@8.4.38):
+ autoprefixer@10.4.19(postcss@8.4.39):
dependencies:
- browserslist: 4.23.0
- caniuse-lite: 1.0.30001627
+ browserslist: 4.23.2
+ caniuse-lite: 1.0.30001642
fraction.js: 4.3.7
normalize-range: 0.1.2
picocolors: 1.0.1
- postcss: 8.4.38
+ postcss: 8.4.39
postcss-value-parser: 4.2.0
axobject-query@4.1.0: {}
@@ -5330,13 +5289,6 @@ snapshots:
dependencies:
fill-range: 7.1.1
- browserslist@4.23.0:
- dependencies:
- caniuse-lite: 1.0.30001627
- electron-to-chromium: 1.4.788
- node-releases: 2.0.14
- update-browserslist-db: 1.0.16(browserslist@4.23.0)
-
browserslist@4.23.2:
dependencies:
caniuse-lite: 1.0.30001642
@@ -5354,8 +5306,6 @@ snapshots:
camelcase@8.0.0: {}
- caniuse-lite@1.0.30001627: {}
-
caniuse-lite@1.0.30001642: {}
capnp-ts@0.7.0:
@@ -5596,8 +5546,6 @@ snapshots:
eastasianwidth@0.2.0: {}
- electron-to-chromium@1.4.788: {}
-
electron-to-chromium@1.4.829: {}
emmet@2.4.7:
@@ -5877,7 +5825,7 @@ snapshots:
get-stream@8.0.1: {}
- github-script@https://codeload.github.com/actions/github-script/tar.gz/35b1cdd1b2c1fc704b1cd9758d10f67e833fcb02:
+ github-script@https://codeload.github.com/actions/github-script/tar.gz/660ec11d825b714d112a6bb9727086bc2cc500b2:
dependencies:
'@actions/core': 1.10.1
'@actions/exec': 1.1.1
@@ -6795,7 +6743,7 @@ snapshots:
miniflare@3.20240620.0:
dependencies:
'@cspotcode/source-map-support': 0.8.1
- acorn: 8.11.3
+ acorn: 8.12.1
acorn-walk: 8.3.2
capnp-ts: 0.7.0
exit-hook: 2.2.1
@@ -6929,7 +6877,7 @@ snapshots:
is-unicode-supported: 2.0.0
log-symbols: 6.0.0
stdin-discarder: 0.2.2
- string-width: 7.1.0
+ string-width: 7.2.0
strip-ansi: 7.1.0
p-limit@2.3.0:
@@ -7059,13 +7007,6 @@ snapshots:
camelcase-css: 2.0.1
postcss: 8.4.39
- postcss-load-config@4.0.2(postcss@8.4.38):
- dependencies:
- lilconfig: 3.1.1
- yaml: 2.4.3
- optionalDependencies:
- postcss: 8.4.38
-
postcss-load-config@4.0.2(postcss@8.4.39):
dependencies:
lilconfig: 3.1.1
@@ -7090,12 +7031,6 @@ snapshots:
postcss-value-parser@4.2.0: {}
- postcss@8.4.38:
- dependencies:
- nanoid: 3.3.7
- picocolors: 1.0.1
- source-map-js: 1.2.0
-
postcss@8.4.39:
dependencies:
nanoid: 3.3.7
@@ -7234,13 +7169,6 @@ snapshots:
unified: 11.0.5
vfile: 6.0.2
- remark-smartypants@3.0.1:
- dependencies:
- retext: 9.0.0
- retext-smartypants: 6.1.0
- unified: 11.0.5
- unist-util-visit: 5.0.0
-
remark-smartypants@3.0.2:
dependencies:
retext: 9.0.0
@@ -7347,7 +7275,7 @@ snapshots:
htmlparser2: 8.0.2
is-plain-object: 5.0.0
parse-srcset: 1.0.2
- postcss: 8.4.38
+ postcss: 8.4.39
sax@1.4.1: {}
@@ -7465,12 +7393,6 @@ snapshots:
emoji-regex: 9.2.2
strip-ansi: 7.1.0
- string-width@7.1.0:
- dependencies:
- emoji-regex: 10.3.0
- get-east-asian-width: 1.2.0
- strip-ansi: 7.1.0
-
string-width@7.2.0:
dependencies:
emoji-regex: 10.3.0
@@ -7689,12 +7611,6 @@ snapshots:
universalify@2.0.1: {}
- update-browserslist-db@1.0.16(browserslist@4.23.0):
- dependencies:
- browserslist: 4.23.0
- escalade: 3.1.2
- picocolors: 1.0.1
-
update-browserslist-db@1.1.0(browserslist@4.23.2):
dependencies:
browserslist: 4.23.2