fix: fix lint by using polyfill
All checks were successful
pipeline / lint-and-format (push) Successful in 4m40s
pipeline / build-and-push-images (push) Successful in 2m25s

This commit is contained in:
2026-04-26 01:19:07 +02:00
parent e82ad73de1
commit 0e0a12513e
2 changed files with 14 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
// Polyfill for Object.groupBy (requires Node.js 21+, we're on 20)
// This must be imported before any code that uses Object.groupBy
if (typeof Object.groupBy === 'undefined') {
Object.groupBy = (items, keyFn) => {
const result = {}
let index = 0
for (const item of items) {
const key = keyFn(item, index++)
;(result[key] ??= []).push(item)
}
return result
}
}

View File

@@ -1,4 +1,5 @@
// @ts-check
import './eslint-polyfill.mjs'
import withNuxt from './.nuxt/eslint.config.mjs'
import js from '@eslint/js'