Skip to content

Commit 4a44e72

Browse files
authored
[Docs Site] Sort by sort_date in CompatibilityFlags component (#19100)
1 parent ab810fa commit 4a44e72

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/components/CompatibilityFlags.astro

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,11 @@ let flags = await getCollection("compatibility-flags");
1616
if (experimental) {
1717
flags = flags.filter((x) => x.data.experimental);
1818
}
19+
20+
flags.sort(
21+
(a, b) =>
22+
new Date(b.data.sort_date).getTime() - new Date(a.data.sort_date).getTime(),
23+
);
1924
---
2025

2126
{

0 commit comments

Comments
 (0)