chore(deps-dev): bump eslint-plugin-unicorn from 58.0.0 to 59.0.0 (#18957)

* chore(deps-dev): bump eslint-plugin-unicorn from 58.0.0 to 59.0.0

Bumps [eslint-plugin-unicorn](https://github.com/sindresorhus/eslint-plugin-unicorn) from 58.0.0 to 59.0.0.
- [Release notes](https://github.com/sindresorhus/eslint-plugin-unicorn/releases)
- [Commits](https://github.com/sindresorhus/eslint-plugin-unicorn/compare/v58.0.0...v59.0.0)

---
updated-dependencies:
- dependency-name: eslint-plugin-unicorn
  dependency-version: 59.0.0
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix: no-unnecessary-array-flat-depth

* fix(eslint): unicorn/prefer-import-meta-properties

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
dependabot[bot]
2025-04-28 21:50:53 +08:00
committed by GitHub
parent 832c1ddcd6
commit 5a824d3367
5 changed files with 21 additions and 142 deletions
+2 -4
View File
@@ -6,13 +6,10 @@ import n from 'eslint-plugin-n';
import globals from 'globals';
import tsParser from '@typescript-eslint/parser';
import yamlParser from 'yaml-eslint-parser';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import js from '@eslint/js';
import { FlatCompat } from '@eslint/eslintrc';
const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
const __dirname = import.meta.dirname;
const compat = new FlatCompat({
baseDirectory: __dirname,
recommendedConfig: js.configs.recommended,
@@ -185,6 +182,7 @@ unicorn.configs.recommended,
'unicorn/prefer-code-point': 'warn',
'unicorn/prefer-global-this': 'off',
'unicorn/prefer-import-meta-properties': 'warn',
'unicorn/prefer-logical-operator-over-ternary': 'warn',
'unicorn/prefer-module': 'off',
'unicorn/prefer-node-protocol': 'off',
+1 -2
View File
@@ -2,7 +2,6 @@ import type { Namespace, Route } from '@/types';
import { directoryImport } from 'directory-import';
import { Hono, type Handler } from 'hono';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import { serveStatic } from '@hono/node-server/serve-static';
import { config } from '@/config';
@@ -11,7 +10,7 @@ import healthz from '@/routes/healthz';
import robotstxt from '@/routes/robots.txt';
import metrics from '@/routes/metrics';
const __dirname = path.dirname(fileURLToPath(import.meta.url));
const __dirname = import.meta.dirname;
let modules: Record<string, { route: Route } | { namespace: Namespace }> = {};
let namespaces: Record<
+1 -1
View File
@@ -56,7 +56,7 @@ async function handler() {
)
);
const fullList = lists.flat(1); // flatten array
const fullList = lists.flat(); // flatten array
// fullList = fullList.filter((item) => item.title !== 'Empty');
const items = await Promise.all(
+1 -1
View File
@@ -177,7 +177,7 @@
"eslint-nibble": "8.1.0",
"eslint-plugin-n": "17.17.0",
"eslint-plugin-prettier": "5.2.6",
"eslint-plugin-unicorn": "58.0.0",
"eslint-plugin-unicorn": "59.0.0",
"eslint-plugin-yml": "1.18.0",
"fs-extra": "11.3.0",
"globals": "16.0.0",
+16 -134
View File
@@ -394,8 +394,8 @@ importers:
specifier: 5.2.6
version: 5.2.6(@types/eslint@9.6.1)(eslint-config-prettier@10.1.2(eslint@9.25.1(jiti@2.4.2)))(eslint@9.25.1(jiti@2.4.2))(prettier@3.5.3)
eslint-plugin-unicorn:
specifier: 58.0.0
version: 58.0.0(eslint@9.25.1(jiti@2.4.2))
specifier: 59.0.0
version: 59.0.0(eslint@9.25.1(jiti@2.4.2))
eslint-plugin-yml:
specifier: 1.18.0
version: 1.18.0(eslint@9.25.1(jiti@2.4.2))
@@ -1383,10 +1383,6 @@ packages:
resolution: {integrity: sha512-RI17tsD2frtDu/3dmI7QRrD4bedNKPM08ziRYaC5AhkGrzIAJelm9kJU1TznK+apx6V+cqRz8tfpEeG3oIyjxw==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
'@eslint/core@0.12.0':
resolution: {integrity: sha512-cmrR6pytBuSMTaBweKoGMwu3EiHiEC+DoyupPmlZ0HxBJBtIxwe+j/E4XPIKNx+Q74c8lXKPwYawBf5glsTkHg==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
'@eslint/core@0.13.0':
resolution: {integrity: sha512-yfkgDw1KR66rkT5A8ci4irzDysN7FRpq3ttJolR88OqQikAWqwA8j5VZyas+vjyBNFIJ7MfybJ9plMILI2UrCw==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -1411,10 +1407,6 @@ packages:
resolution: {integrity: sha512-RBMg5FRL0I0gs51M/guSAj5/e14VQ4tpZnQNWwuDT66P14I43ItmPfIZRhO9fUVIPOAQXU47atlywZ/czoqFPA==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
'@eslint/plugin-kit@0.2.7':
resolution: {integrity: sha512-JubJ5B2pJ4k4yGxaNLdbjrnk9d/iDz6/q8wOilpIowd6PJPgaxCuHBnBszq7Ce2TyMrywm5r4PnKm6V3iiZF+g==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
'@eslint/plugin-kit@0.2.8':
resolution: {integrity: sha512-ZAoA40rNMPwSm+AeHpCq8STiNAwzWLJuP8Xv4CHIc9wv/PSuExjMrmjfYNj682vW0OOiZ1HKxzvjQr9XZIisQA==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -2495,9 +2487,6 @@ packages:
'@types/node@22.15.3':
resolution: {integrity: sha512-lX7HFZeHf4QG/J7tBZqrCAXwz9J5RD56Y6MpP0eJkka8p+K0RY/yBTW7CYFJ4VGCclxqOLKmiGP5juQc6MKgcw==}
'@types/normalize-package-data@2.4.4':
resolution: {integrity: sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==}
'@types/pg-pool@2.0.6':
resolution: {integrity: sha512-TaAUE5rq2VQYxab5Ts7WZhKNmuN78Q6PiFonTDdpbx8a1H0M1vhy3rhiMjl+e2iHmogyMw7jZF4FrE6eJUy5HQ==}
@@ -2960,8 +2949,8 @@ packages:
resolution: {integrity: sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==}
engines: {node: '>=10'}
caniuse-lite@1.0.30001707:
resolution: {integrity: sha512-3qtRjw/HQSMlDWf+X79N206fepf4SOOU6SQLMaq/0KkZLmSjPxAkBOQQ+FxbHKfHmYLZFfdWsO3KA90ceHPSnw==}
caniuse-lite@1.0.30001715:
resolution: {integrity: sha512-7ptkFGMm2OAOgvZpwgA4yjQ5SQbrNVGdRjzH0pBdy1Fasvcr+KAeECmbCAECzTuDuoX0FCY8KzUxjf9+9kfZEw==}
caseless@0.12.0:
resolution: {integrity: sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==}
@@ -3420,8 +3409,8 @@ packages:
engines: {node: '>=14'}
hasBin: true
electron-to-chromium@1.5.128:
resolution: {integrity: sha512-bo1A4HH/NS522Ws0QNFIzyPcyUUNV/yyy70Ho1xqfGYzPUme2F/xr4tlEOuM6/A538U1vDA7a4XfCd1CKRegKQ==}
electron-to-chromium@1.5.143:
resolution: {integrity: sha512-QqklJMOFBMqe46k8iIOwA9l2hz57V2OKMmP5eSWcUvwx+mASAsbU+wkF1pHjn9ZVSBPrsYWr4/W/95y5SwYg2g==}
ellipsize@0.1.0:
resolution: {integrity: sha512-5gxbEjcb/Z2n6TTmXZx9wVi3N/DOzE7RXY3Xg9dakDuhX/izwumB9rGjeWUV6dTA0D0+juvo+JonZgNR9sgA5A==}
@@ -3584,8 +3573,8 @@ packages:
eslint-config-prettier:
optional: true
eslint-plugin-unicorn@58.0.0:
resolution: {integrity: sha512-fc3iaxCm9chBWOHPVjn+Czb/wHS0D2Mko7wkOdobqo9R2bbFObc4LyZaLTNy0mhZOP84nKkLhTUQxlLOZ7EjKw==}
eslint-plugin-unicorn@59.0.0:
resolution: {integrity: sha512-7IEeqkymGa7tr6wTWS4DolfXnfcE3QjcD0g7I+qCfV5GPMvVsFsLT7zTIYvnudqwAm5nWekdGIOTTXA93Sz9Ow==}
engines: {node: ^18.20.0 || ^20.10.0 || >=21.0.0}
peerDependencies:
eslint: '>=9.22.0'
@@ -4037,10 +4026,6 @@ packages:
hookable@5.5.3:
resolution: {integrity: sha512-Yc+BQe8SvoXH1643Qez1zqLRmbA5rCL+sSmk6TVos0LWVfNIB7PGncdlId77WzLGSIB5KaWgTaNTs2lNVEI6VQ==}
hosted-git-info@7.0.2:
resolution: {integrity: sha512-puUZAUKT5m8Zzvs72XWy3HtvVbTWljRE66cP60bxJzAqf2DgICo7lYTY2IHUmLnNpjYvw5bvmoHvPc0QO2a62w==}
engines: {node: ^16.14.0 || >=18.0.0}
html-encoding-sniffer@4.0.0:
resolution: {integrity: sha512-Y22oTqIU4uuPgEemfz7NDJz6OeKf12Lsu+QC+s3BVpda64lTiMYCyGwg5ki4vFxkMwQdeZDl2adZoqUgdFuTgQ==}
engines: {node: '>=18'}
@@ -4153,10 +4138,6 @@ packages:
resolution: {integrity: sha512-m6FAo/spmsW2Ab2fU35JTYwtOKa2yAwXSwgjSv1TJzh4Mh7mC3lzAOVLBprb72XsTrgkEIsl7YrFNAiDiRhIGg==}
engines: {node: '>=12'}
index-to-position@1.0.0:
resolution: {integrity: sha512-sCO7uaLVhRJ25vz1o8s9IFM3nVS4DkuQnyjMwiQPKvQuBYBDmb8H7zx8ki7nVh4HJQOdVWebyvLE0qt+clruxA==}
engines: {node: '>=18'}
inflight@1.0.6:
resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==}
deprecated: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
@@ -4929,10 +4910,6 @@ packages:
engines: {node: ^18.17.0 || >=20.5.0}
hasBin: true
normalize-package-data@6.0.2:
resolution: {integrity: sha512-V6gygoYb/5EmNI+MEGrWkC+e6+Rr7mTmfHrxDbLzxQogBkgzo76rkok0Am6thgSF7Mv2nLOajAJj5vDJZEFn7g==}
engines: {node: ^16.14.0 || >=18.0.0}
normalize-url@8.0.1:
resolution: {integrity: sha512-IO9QvjUMWxPQQhs60oOu10CRkWCiZzSUkzbXGGV9pviYl1fXYcvkzQ5jV9z8Y6un8ARoVRl4EtC6v6jNqbaJ/w==}
engines: {node: '>=14.16'}
@@ -5076,10 +5053,6 @@ packages:
resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==}
engines: {node: '>=8'}
parse-json@8.2.0:
resolution: {integrity: sha512-eONBZy4hm2AgxjNFd8a4nyDJnzUAH0g34xSQAwWEVGCjdZ4ZL7dKZBfq267GWP/JaS9zW62Xs2FeAdDvpHHJGQ==}
engines: {node: '>=18'}
parse-srcset@1.0.2:
resolution: {integrity: sha512-/2qh0lav6CmI15FzA3i/2Bzk2zCgQhGMkvhOhKNcBVQ1ldgpbfiNTVslmooUmWJcADi1f1kIeynbDRVzNlfR6Q==}
@@ -5375,14 +5348,6 @@ packages:
re2js@1.1.0:
resolution: {integrity: sha512-ovDCIb2ZQR7Do3NzH2XEuXOzqd1q8srvkeaOVMf+EZNt1Z4JoUVvNKCR9qf8EbqoPhvLknkoyiiBzoQtmuzIbQ==}
read-package-up@11.0.0:
resolution: {integrity: sha512-MbgfoNPANMdb4oRBNg5eqLbB2t2r+o5Ua1pNt8BqGp4I0FJZhuVSOj3PaBPni4azWuSzEdNn2evevzVmEk1ohQ==}
engines: {node: '>=18'}
read-pkg@9.0.1:
resolution: {integrity: sha512-9viLL4/n1BJUCT1NXVTdS1jtm80yDEgR5T4yCelII49Mbj0v1rZdKqj7zCiYdbB0CuCgdrvHcNogAKTFPBocFA==}
engines: {node: '>=18'}
readable-stream@3.6.2:
resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==}
engines: {node: '>= 6'}
@@ -5679,18 +5644,6 @@ packages:
resolution: {integrity: sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==}
engines: {node: '>= 8'}
spdx-correct@3.2.0:
resolution: {integrity: sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==}
spdx-exceptions@2.5.0:
resolution: {integrity: sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==}
spdx-expression-parse@3.0.1:
resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==}
spdx-license-ids@3.0.21:
resolution: {integrity: sha512-Bvg/8F5XephndSK3JffaRqdT+gyhfqIPwDHpX80tJrF8QQRYMo8sNMeaZ2Dp5+jhwKnUmIOyFFQfHRkjJm5nXg==}
split-on-first@1.1.0:
resolution: {integrity: sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw==}
engines: {node: '>=6'}
@@ -6116,10 +6069,6 @@ packages:
resolution: {integrity: sha512-6t3foTQI9qne+OZoVQB/8x8rk2k1eVy1gRXhV3oFQ5T6R1dqQ1xtin3XqSlx3+ATBkliTaR/hHyJBm+LVPNM8w==}
engines: {node: '>=4'}
unicorn-magic@0.1.0:
resolution: {integrity: sha512-lRfVq8fE8gz6QMBuDM6a+LO3IAzTi05H6gCVaUpir2E1Rwpo4ZUog45KpNXKC/Mn3Yb9UDuHumeFTo9iV/D9FQ==}
engines: {node: '>=18'}
unified@11.0.5:
resolution: {integrity: sha512-xKvGhPWw3k84Qjh8bI3ZeJjqnyadK+GEFtazSfZv/rKeTkTjOJho6mFqh2SM96iIcZokxiOpg78GazTSg8+KHA==}
@@ -6206,9 +6155,6 @@ packages:
valid-url@1.0.9:
resolution: {integrity: sha512-QQDsV8OnSf5Uc30CKSwG9lnhMPe6exHtTXLRYX8uMwKENy640pU+2BgBL0LRbDh/eYRahNCS7aewCx0wf3NYVA==}
validate-npm-package-license@3.0.4:
resolution: {integrity: sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==}
verror@1.10.0:
resolution: {integrity: sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw==}
engines: {'0': node >=0.6.0}
@@ -7451,10 +7397,6 @@ snapshots:
'@eslint/config-helpers@0.2.1': {}
'@eslint/core@0.12.0':
dependencies:
'@types/json-schema': 7.0.15
'@eslint/core@0.13.0':
dependencies:
'@types/json-schema': 7.0.15
@@ -7493,11 +7435,6 @@ snapshots:
'@eslint/object-schema@2.1.6': {}
'@eslint/plugin-kit@0.2.7':
dependencies:
'@eslint/core': 0.12.0
levn: 0.4.1
'@eslint/plugin-kit@0.2.8':
dependencies:
'@eslint/core': 0.13.0
@@ -8586,8 +8523,6 @@ snapshots:
dependencies:
undici-types: 6.21.0
'@types/normalize-package-data@2.4.4': {}
'@types/pg-pool@2.0.6':
dependencies:
'@types/pg': 8.6.1
@@ -9058,8 +8993,8 @@ snapshots:
browserslist@4.24.4:
dependencies:
caniuse-lite: 1.0.30001707
electron-to-chromium: 1.5.128
caniuse-lite: 1.0.30001715
electron-to-chromium: 1.5.143
node-releases: 2.0.19
update-browserslist-db: 1.1.3(browserslist@4.24.4)
@@ -9125,7 +9060,7 @@ snapshots:
camelcase@6.3.0: {}
caniuse-lite@1.0.30001707: {}
caniuse-lite@1.0.30001715: {}
caseless@0.12.0: {}
@@ -9589,7 +9524,7 @@ snapshots:
minimatch: 9.0.1
semver: 7.7.1
electron-to-chromium@1.5.128: {}
electron-to-chromium@1.5.143: {}
ellipsize@0.1.0: {}
@@ -9797,22 +9732,22 @@ snapshots:
'@types/eslint': 9.6.1
eslint-config-prettier: 10.1.2(eslint@9.25.1(jiti@2.4.2))
eslint-plugin-unicorn@58.0.0(eslint@9.25.1(jiti@2.4.2)):
eslint-plugin-unicorn@59.0.0(eslint@9.25.1(jiti@2.4.2)):
dependencies:
'@babel/helper-validator-identifier': 7.25.9
'@eslint-community/eslint-utils': 4.5.1(eslint@9.25.1(jiti@2.4.2))
'@eslint/plugin-kit': 0.2.7
'@eslint-community/eslint-utils': 4.6.1(eslint@9.25.1(jiti@2.4.2))
'@eslint/plugin-kit': 0.2.8
ci-info: 4.2.0
clean-regexp: 1.0.0
core-js-compat: 3.41.0
eslint: 9.25.1(jiti@2.4.2)
esquery: 1.6.0
find-up-simple: 1.0.1
globals: 16.0.0
indent-string: 5.0.0
is-builtin-module: 5.0.0
jsesc: 3.1.0
pluralize: 8.0.0
read-package-up: 11.0.0
regexp-tree: 0.1.27
regjsparser: 0.12.0
semver: 7.7.1
@@ -10377,10 +10312,6 @@ snapshots:
hookable@5.5.3: {}
hosted-git-info@7.0.2:
dependencies:
lru-cache: 10.4.3
html-encoding-sniffer@4.0.0:
dependencies:
whatwg-encoding: 3.1.1
@@ -10525,8 +10456,6 @@ snapshots:
indent-string@5.0.0: {}
index-to-position@1.0.0: {}
inflight@1.0.6:
dependencies:
once: 1.4.0
@@ -11366,12 +11295,6 @@ snapshots:
dependencies:
abbrev: 3.0.0
normalize-package-data@6.0.2:
dependencies:
hosted-git-info: 7.0.2
semver: 7.7.1
validate-npm-package-license: 3.0.4
normalize-url@8.0.1: {}
notion-to-md@3.1.8:
@@ -11578,12 +11501,6 @@ snapshots:
json-parse-even-better-errors: 2.3.1
lines-and-columns: 1.2.4
parse-json@8.2.0:
dependencies:
'@babel/code-frame': 7.26.2
index-to-position: 1.0.0
type-fest: 4.38.0
parse-srcset@1.0.2: {}
parse5-htmlparser2-tree-adapter@7.1.0:
@@ -11894,20 +11811,6 @@ snapshots:
re2js@1.1.0: {}
read-package-up@11.0.0:
dependencies:
find-up-simple: 1.0.1
read-pkg: 9.0.1
type-fest: 4.38.0
read-pkg@9.0.1:
dependencies:
'@types/normalize-package-data': 2.4.4
normalize-package-data: 6.0.2
parse-json: 8.2.0
type-fest: 4.38.0
unicorn-magic: 0.1.0
readable-stream@3.6.2:
dependencies:
inherits: 2.0.4
@@ -12243,20 +12146,6 @@ snapshots:
source-map@0.7.4: {}
spdx-correct@3.2.0:
dependencies:
spdx-expression-parse: 3.0.1
spdx-license-ids: 3.0.21
spdx-exceptions@2.5.0: {}
spdx-expression-parse@3.0.1:
dependencies:
spdx-exceptions: 2.5.0
spdx-license-ids: 3.0.21
spdx-license-ids@3.0.21: {}
split-on-first@1.1.0: {}
split-on-first@3.0.0: {}
@@ -12672,8 +12561,6 @@ snapshots:
unicode-property-aliases-ecmascript@2.1.0: {}
unicorn-magic@0.1.0: {}
unified@11.0.5:
dependencies:
'@types/unist': 3.0.3
@@ -12742,11 +12629,6 @@ snapshots:
valid-url@1.0.9: {}
validate-npm-package-license@3.0.4:
dependencies:
spdx-correct: 3.2.0
spdx-expression-parse: 3.0.1
verror@1.10.0:
dependencies:
assert-plus: 1.0.0