chore: support proper badge collection sorting

This commit is contained in:
Cory Dransfeldt 2024-07-16 11:49:31 -07:00
parent e45261bb31
commit 05cd107af6
No known key found for this signature in database
3 changed files with 4 additions and 4 deletions

4
package-lock.json generated
View file

@ -1,12 +1,12 @@
{ {
"name": "coryd.dev", "name": "coryd.dev",
"version": "20.9.3", "version": "20.9.4",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "coryd.dev", "name": "coryd.dev",
"version": "20.9.3", "version": "20.9.4",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@cdransf/api-text": "^1.4.0", "@cdransf/api-text": "^1.4.0",

View file

@ -1,6 +1,6 @@
{ {
"name": "coryd.dev", "name": "coryd.dev",
"version": "20.9.3", "version": "20.9.4",
"description": "The source for my personal site. Built using 11ty (and other tools).", "description": "The source for my personal site. Built using 11ty (and other tools).",
"type": "module", "type": "module",
"scripts": { "scripts": {

View file

@ -20,7 +20,7 @@ const fetchAllBadges = async () => {
const transformedData = data.map(badge => ({ const transformedData = data.map(badge => ({
...badge, ...badge,
image: badge['image']['filename_disk'], image: badge['image']['filename_disk'],
})) })).sort((a, b) => a.sort - b.sort)
return transformedData return transformedData
} }