Skip to content

Commit

Permalink
[Docs Site] Sort by sort_date in CompatibilityFlags component (#19100)
Browse files Browse the repository at this point in the history
  • Loading branch information
KianNH authored Jan 9, 2025
1 parent ab810fa commit 4a44e72
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/components/CompatibilityFlags.astro
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ let flags = await getCollection("compatibility-flags");
if (experimental) {
flags = flags.filter((x) => x.data.experimental);
}
flags.sort(
(a, b) =>
new Date(b.data.sort_date).getTime() - new Date(a.data.sort_date).getTime(),
);
---

{
Expand Down

0 comments on commit 4a44e72

Please sign in to comment.