From 1cb9b1b2279518faa916eca751bc15d077e130b6 Mon Sep 17 00:00:00 2001 From: Jimmy Guzman <30631540+jimmy-guzman@users.noreply.github.com> Date: Fri, 6 Dec 2024 18:40:10 -0600 Subject: [PATCH] =?UTF-8?q?feat:=20=E2=9C=A8=20add=20`eslint-plugin-jsdoc`?= =?UTF-8?q?=20rules=20(#117)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 🏁 Closes: #88 --- package.json | 11 +- pnpm-lock.yaml | 584 ++++++++-------- src/configs/jsdoc.ts | 13 + src/factory.spec.ts | 27 +- src/factory.ts | 2 + src/rules.gen.d.ts | 745 +++++++++++++++++++++ src/rules/__snapshots__/jsdoc.spec.ts.snap | 74 ++ src/rules/jsdoc.spec.ts | 5 + src/rules/jsdoc.ts | 19 + src/types.ts | 3 +- src/utils/interop-default.ts | 2 +- 11 files changed, 1143 insertions(+), 342 deletions(-) create mode 100644 src/configs/jsdoc.ts create mode 100644 src/rules/__snapshots__/jsdoc.spec.ts.snap create mode 100644 src/rules/jsdoc.spec.ts create mode 100644 src/rules/jsdoc.ts diff --git a/package.json b/package.json index 67f033d..c3364eb 100644 --- a/package.json +++ b/package.json @@ -62,6 +62,7 @@ "eslint-plugin-import-x": "^4.5.0", "eslint-plugin-jest": "^28.9.0", "eslint-plugin-jest-dom": "^5.5.0", + "eslint-plugin-jsdoc": "^50.6.0", "eslint-plugin-jsx-a11y": "^6.10.2", "eslint-plugin-n": "^17.14.0", "eslint-plugin-perfectionist": "^4.2.0", @@ -88,14 +89,14 @@ "@semantic-release/git": "10.0.1", "@semantic-release/npm": "12.0.1", "@semantic-release/release-notes-generator": "14.0.1", - "@tanstack/react-query": "5.62.2", + "@tanstack/react-query": "5.62.3", "@testing-library/dom": "10.4.0", "@testing-library/react": "16.1.0", "@total-typescript/ts-reset": "0.6.1", "@types/node": "22.10.1", "@types/react": "18.3.12", "@vitest/coverage-v8": "2.1.8", - "astro": "4.16.16", + "astro": "5.0.3", "clean-pkg-json": "1.2.0", "commitlint": "19.6.0", "eslint": "9.16.0", @@ -103,8 +104,8 @@ "gitzy": "5.7.1", "is-ci": "3.0.1", "jiti": "2.4.1", - "lefthook": "1.8.5", - "next": "15.0.3", + "lefthook": "1.9.0", + "next": "15.0.4", "pkgroll": "2.5.1", "prettier": "3.4.2", "react": "18.3.1", @@ -118,7 +119,7 @@ "peerDependencies": { "eslint": "^9.10.0" }, - "packageManager": "pnpm@9.14.4", + "packageManager": "pnpm@9.15.0", "engines": { "node": ">= 20" }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2234f81..b7169bd 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -53,6 +53,9 @@ importers: eslint-plugin-jest-dom: specifier: ^5.5.0 version: 5.5.0(@testing-library/dom@10.4.0)(eslint@9.16.0(jiti@2.4.1)) + eslint-plugin-jsdoc: + specifier: ^50.6.0 + version: 50.6.0(eslint@9.16.0(jiti@2.4.1)) eslint-plugin-jsx-a11y: specifier: ^6.10.2 version: 6.10.2(eslint@9.16.0(jiti@2.4.1)) @@ -127,8 +130,8 @@ importers: specifier: 14.0.1 version: 14.0.1(semantic-release@24.2.0(typescript@5.7.2)) '@tanstack/react-query': - specifier: 5.62.2 - version: 5.62.2(react@18.3.1) + specifier: 5.62.3 + version: 5.62.3(react@18.3.1) '@testing-library/dom': specifier: 10.4.0 version: 10.4.0 @@ -148,8 +151,8 @@ importers: specifier: 2.1.8 version: 2.1.8(vitest@2.1.8(@types/node@22.10.1)) astro: - specifier: 4.16.16 - version: 4.16.16(@types/node@22.10.1)(rollup@4.27.2)(typescript@5.7.2) + specifier: 5.0.3 + version: 5.0.3(@types/node@22.10.1)(jiti@2.4.1)(rollup@4.27.2)(tsx@4.19.2)(typescript@5.7.2)(yaml@2.6.0) clean-pkg-json: specifier: 1.2.0 version: 1.2.0 @@ -172,11 +175,11 @@ importers: specifier: 2.4.1 version: 2.4.1 lefthook: - specifier: 1.8.5 - version: 1.8.5 + specifier: 1.9.0 + version: 1.9.0 next: - specifier: 15.0.3 - version: 15.0.3(@babel/core@7.26.0)(@playwright/test@1.49.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) + specifier: 15.0.4 + version: 15.0.4(@playwright/test@1.49.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1) pkgroll: specifier: 2.5.1 version: 2.5.1(typescript@5.7.2) @@ -218,19 +221,19 @@ packages: '@astrojs/compiler@2.10.3': resolution: {integrity: sha512-bL/O7YBxsFt55YHU021oL+xz+B/9HvGNId3F9xURN16aeqDK9juHGktdkCSXz+U4nqFACq6ZFvWomOzhV+zfPw==} - '@astrojs/internal-helpers@0.4.1': - resolution: {integrity: sha512-bMf9jFihO8YP940uD70SI/RDzIhUHJAolWVcO1v5PUivxGKvfLZTLTVVxEYzGYyPsA3ivdLNqMnL5VgmQySa+g==} + '@astrojs/internal-helpers@0.4.2': + resolution: {integrity: sha512-EdDWkC3JJVcpGpqJAU/5hSk2LKXyG3mNGkzGoAuyK+xoPHbaVdSuIWoN1QTnmK3N/gGfaaAfM8gO2KDCAW7S3w==} - '@astrojs/markdown-remark@5.3.0': - resolution: {integrity: sha512-r0Ikqr0e6ozPb5bvhup1qdWnSPUvQu6tub4ZLYaKyG50BXZ0ej6FhGz3GpChKpH7kglRFPObJd/bDyf2VM9pkg==} + '@astrojs/markdown-remark@6.0.0': + resolution: {integrity: sha512-Tabo7xM44Pz2Yf9qpdaCCgxRmtaypi2YCinqTUNefDrWUa+OyKW62OuNeCaGwNh/ys+QAd9FUWN5/3HgPWjP4Q==} - '@astrojs/prism@3.1.0': - resolution: {integrity: sha512-Z9IYjuXSArkAUx3N6xj6+Bnvx8OdUSHA8YoOgyepp3+zJmtVYJIl/I18GozdJVW1p5u/CNpl3Km7/gwTJK85cw==} - engines: {node: ^18.17.1 || ^20.3.0 || >=21.0.0} + '@astrojs/prism@3.2.0': + resolution: {integrity: sha512-GilTHKGCW6HMq7y3BUv9Ac7GMe/MO9gi9GW62GzKtth0SwukCu/qp2wLiGpEujhY+VVhaG9v7kv/5vFzvf4NYw==} + engines: {node: ^18.17.1 || ^20.3.0 || >=22.0.0} - '@astrojs/telemetry@3.1.0': - resolution: {integrity: sha512-/ca/+D8MIKEC8/A9cSaPUqQNZm+Es/ZinRv0ZAzvu2ios7POQSsVD+VOj7/hypWNsNM3T7RpfgNq7H2TU1KEHA==} - engines: {node: ^18.17.1 || ^20.3.0 || >=21.0.0} + '@astrojs/telemetry@3.2.0': + resolution: {integrity: sha512-wxhSKRfKugLwLlr4OFfcqovk+LIFtKwLyGPqMsv+9/ibqqnW3Gv7tBhtKEb0gAyUAC4G9BTVQeQahqnQAhd6IQ==} + engines: {node: ^18.17.1 || ^20.3.0 || >=22.0.0} '@babel/code-frame@7.26.2': resolution: {integrity: sha512-RJlIHRueQgwWitWgF8OdFYGZX328Ax5BCemNGlqHfplnRT9ESi8JkFlvaVYbS+UubVY6dpv87Fs2u5M29iNFVQ==} @@ -315,24 +318,12 @@ packages: engines: {node: '>=6.0.0'} hasBin: true - '@babel/plugin-syntax-jsx@7.25.9': - resolution: {integrity: sha512-ld6oezHQMZsZfp6pWtbjaNDF2tiiCYYDqQszHt5VV437lewP9aSi2Of99CK0D0XB21k7FLgnLcmQKyKzynfeAA==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-private-methods@7.25.9': resolution: {integrity: sha512-D/JUozNpQLAPUVusvqMxyvjzllRaF8/nSrP1s2YGQT/W4LHK4xxsMcHjhOGTS01mp9Hda8nswb+FblLdJornQw==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 - '@babel/plugin-transform-react-jsx@7.25.9': - resolution: {integrity: sha512-s5XwpQYCqGerXl+Pu6VDL3x0j2d82eiV77UJ8a2mDHAW7j9SWRqQ2y1fNo1Z74CdcYipl5Z41zvjj4Nfzq36rw==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - '@babel/runtime@7.26.0': resolution: {integrity: sha512-FDSOghenHTiToteC/QRlv2q3DhPZ/oOXTBoirfWNx1Cx3TMVcGWQtMMmQcSvb/JjpNeGzx8Pq/b4fKEJuWm1sw==} engines: {node: '>=6.9.0'} @@ -428,6 +419,10 @@ packages: '@emnapi/runtime@1.3.1': resolution: {integrity: sha512-kEBmG8KyqtxJZv+ygbEim+KCGtIq1fC22Ms3S4ziXmYKm8uyoLX0MHONVKwp+9opg390VaKRNt4a7A9NwmpNhw==} + '@es-joy/jsdoccomment@0.49.0': + resolution: {integrity: sha512-xjZTSFgECpb9Ohuk5yMX5RhUEbfeQcuOp8IF60e+wyzWEF0M5xeSgqsfLtvPEX8BIyOX9saZqzuGPmZ8oWc+5Q==} + engines: {node: '>=16'} + '@esbuild/aix-ppc64@0.21.5': resolution: {integrity: sha512-1SDgH6ZSPTlggy1yI6+Dbkiz8xzpHJEVAlF/AM1tHPLsf5STom9rwtjE4hKAF20FfXXNTFqEYXyJNWh1GiZedQ==} engines: {node: '>=12'} @@ -1064,56 +1059,56 @@ packages: '@jsdevtools/ono@7.1.3': resolution: {integrity: sha512-4JQNk+3mVzK3xh2rqd6RB4J46qUR19azEHBneZyTZM+c456qOrbbM/5xcR8huNCCcbVt7+UmizG6GuUvPvKUYg==} - '@next/env@15.0.3': - resolution: {integrity: sha512-t9Xy32pjNOvVn2AS+Utt6VmyrshbpfUMhIjFO60gI58deSo/KgLOp31XZ4O+kY/Is8WAGYwA5gR7kOb1eORDBA==} + '@next/env@15.0.4': + resolution: {integrity: sha512-WNRvtgnRVDD4oM8gbUcRc27IAhaL4eXQ/2ovGbgLnPGUvdyDr8UdXP4Q/IBDdAdojnD2eScryIDirv0YUCjUVw==} '@next/eslint-plugin-next@15.0.3': resolution: {integrity: sha512-3Ln/nHq2V+v8uIaxCR6YfYo7ceRgZNXfTd3yW1ukTaFbO+/I8jNakrjYWODvG9BuR2v5kgVtH/C8r0i11quOgw==} - '@next/swc-darwin-arm64@15.0.3': - resolution: {integrity: sha512-s3Q/NOorCsLYdCKvQlWU+a+GeAd3C8Rb3L1YnetsgwXzhc3UTWrtQpB/3eCjFOdGUj5QmXfRak12uocd1ZiiQw==} + '@next/swc-darwin-arm64@15.0.4': + resolution: {integrity: sha512-QecQXPD0yRHxSXWL5Ff80nD+A56sUXZG9koUsjWJwA2Z0ZgVQfuy7gd0/otjxoOovPVHR2eVEvPMHbtZP+pf9w==} engines: {node: '>= 10'} cpu: [arm64] os: [darwin] - '@next/swc-darwin-x64@15.0.3': - resolution: {integrity: sha512-Zxl/TwyXVZPCFSf0u2BNj5sE0F2uR6iSKxWpq4Wlk/Sv9Ob6YCKByQTkV2y6BCic+fkabp9190hyrDdPA/dNrw==} + '@next/swc-darwin-x64@15.0.4': + resolution: {integrity: sha512-pb7Bye3y1Og3PlCtnz2oO4z+/b3pH2/HSYkLbL0hbVuTGil7fPen8/3pyyLjdiTLcFJ+ymeU3bck5hd4IPFFCA==} engines: {node: '>= 10'} cpu: [x64] os: [darwin] - '@next/swc-linux-arm64-gnu@15.0.3': - resolution: {integrity: sha512-T5+gg2EwpsY3OoaLxUIofmMb7ohAUlcNZW0fPQ6YAutaWJaxt1Z1h+8zdl4FRIOr5ABAAhXtBcpkZNwUcKI2fw==} + '@next/swc-linux-arm64-gnu@15.0.4': + resolution: {integrity: sha512-12oSaBFjGpB227VHzoXF3gJoK2SlVGmFJMaBJSu5rbpaoT5OjP5OuCLuR9/jnyBF1BAWMs/boa6mLMoJPRriMA==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - '@next/swc-linux-arm64-musl@15.0.3': - resolution: {integrity: sha512-WkAk6R60mwDjH4lG/JBpb2xHl2/0Vj0ZRu1TIzWuOYfQ9tt9NFsIinI1Epma77JVgy81F32X/AeD+B2cBu/YQA==} + '@next/swc-linux-arm64-musl@15.0.4': + resolution: {integrity: sha512-QARO88fR/a+wg+OFC3dGytJVVviiYFEyjc/Zzkjn/HevUuJ7qGUUAUYy5PGVWY1YgTzeRYz78akQrVQ8r+sMjw==} engines: {node: '>= 10'} cpu: [arm64] os: [linux] - '@next/swc-linux-x64-gnu@15.0.3': - resolution: {integrity: sha512-gWL/Cta1aPVqIGgDb6nxkqy06DkwJ9gAnKORdHWX1QBbSZZB+biFYPFti8aKIQL7otCE1pjyPaXpFzGeG2OS2w==} + '@next/swc-linux-x64-gnu@15.0.4': + resolution: {integrity: sha512-Z50b0gvYiUU1vLzfAMiChV8Y+6u/T2mdfpXPHraqpypP7yIT2UV9YBBhcwYkxujmCvGEcRTVWOj3EP7XW/wUnw==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - '@next/swc-linux-x64-musl@15.0.3': - resolution: {integrity: sha512-QQEMwFd8r7C0GxQS62Zcdy6GKx999I/rTO2ubdXEe+MlZk9ZiinsrjwoiBL5/57tfyjikgh6GOU2WRQVUej3UA==} + '@next/swc-linux-x64-musl@15.0.4': + resolution: {integrity: sha512-7H9C4FAsrTAbA/ENzvFWsVytqRYhaJYKa2B3fyQcv96TkOGVMcvyS6s+sj4jZlacxxTcn7ygaMXUPkEk7b78zw==} engines: {node: '>= 10'} cpu: [x64] os: [linux] - '@next/swc-win32-arm64-msvc@15.0.3': - resolution: {integrity: sha512-9TEp47AAd/ms9fPNgtgnT7F3M1Hf7koIYYWCMQ9neOwjbVWJsHZxrFbI3iEDJ8rf1TDGpmHbKxXf2IFpAvheIQ==} + '@next/swc-win32-arm64-msvc@15.0.4': + resolution: {integrity: sha512-Z/v3WV5xRaeWlgJzN9r4PydWD8sXV35ywc28W63i37G2jnUgScA4OOgS8hQdiXLxE3gqfSuHTicUhr7931OXPQ==} engines: {node: '>= 10'} cpu: [arm64] os: [win32] - '@next/swc-win32-x64-msvc@15.0.3': - resolution: {integrity: sha512-VNAz+HN4OGgvZs6MOoVfnn41kBzT+M+tB+OK4cww6DNyWS6wKaDpaAm/qLeOUbnMh0oVx1+mg0uoYARF69dJyA==} + '@next/swc-win32-x64-msvc@15.0.4': + resolution: {integrity: sha512-NGLchGruagh8lQpDr98bHLyWJXOBSmkEAfK980OiNBa7vNm6PsNoPvzTfstT78WyOeMRQphEQ455rggd7Eo+Dw==} engines: {node: '>= 10'} cpu: [x64] os: [win32] @@ -1564,11 +1559,11 @@ packages: peerDependencies: eslint: ^8.57.0 || ^9.0.0 - '@tanstack/query-core@5.62.2': - resolution: {integrity: sha512-LcwVcC5qpsDpHcqlXUUL5o9SaOBwhNkGeV+B06s0GBoyBr8FqXPuXT29XzYXR36lchhnerp6XO+CWc84/vh7Zg==} + '@tanstack/query-core@5.62.3': + resolution: {integrity: sha512-Jp/nYoz8cnO7kqhOlSv8ke/0MJRJVGuZ0P/JO9KQ+f45mpN90hrerzavyTKeSoT/pOzeoOUkv1Xd0wPsxAWXfg==} - '@tanstack/react-query@5.62.2': - resolution: {integrity: sha512-fkTpKKfwTJtVPKVR+ag7YqFgG/7TRVVPzduPAUF9zRCiiA8Wu305u+KJl8rCrh98Qce77vzIakvtUyzWLtaPGA==} + '@tanstack/react-query@5.62.3': + resolution: {integrity: sha512-y2zDNKuhgiuMgsKkqd4AcsLIBiCfEO8U11AdrtAUihmLbRNztPrlcZqx2lH1GacZsx+y1qRRbCcJLYTtF1vKsw==} peerDependencies: react: ^18 || ^19 @@ -1597,18 +1592,6 @@ packages: '@types/aria-query@5.0.4': resolution: {integrity: sha512-rfT93uj5s0PRL7EzccGMs3brplhcrghnDoV26NqKhCAS1hVo+WdNsPvE/yb6ilfr5hi2MEk6d5EWJTKdxg8jVw==} - '@types/babel__core@7.20.5': - resolution: {integrity: sha512-qoQprZvz5wQFJwMDqeseRXWv3rqMvhgpbXFfVyWhbx9X47POIA6i/+dXefEmZKoAgOaTdaIgNSMqMIU61yRyzA==} - - '@types/babel__generator@7.6.8': - resolution: {integrity: sha512-ASsj+tpEDsEiFr1arWrlN6V3mdfjRMZt6LtK/Vp/kreFLnr5QH5+DhvD5nINYZXzwJvXeGq+05iUXcAzVrqWtw==} - - '@types/babel__template@7.4.4': - resolution: {integrity: sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A==} - - '@types/babel__traverse@7.20.6': - resolution: {integrity: sha512-r1bzfrm0tomOI8g1SzvCaQHo6Lcv6zu0EA+W2kHrt8dyrHQxGzBBL4kdkzIS+jBMV+EYcMAEAqXqYaLJq5rOZg==} - '@types/conventional-commits-parser@5.0.0': resolution: {integrity: sha512-loB369iXNmAZglwWATL+WRe+CRMmmBPtpolYzIebFaX4YA3x+BEfLqhUAV9WanycKI3TG1IMr5bMJDajDKLlUQ==} @@ -1885,6 +1868,10 @@ packages: any-promise@1.3.0: resolution: {integrity: sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==} + are-docs-informative@0.0.2: + resolution: {integrity: sha512-ixiS0nLNNG5jNQzgZJNoUpBKdo9yTYZMGJ+QgT2jmjR7G7+QHRCc4v6LQ3NgE7EBJq+o0ams3waJwkrlBom8Ig==} + engines: {node: '>=14'} + argparse@1.0.10: resolution: {integrity: sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==} @@ -1954,9 +1941,9 @@ packages: resolution: {integrity: sha512-F6NW1RJo5pp2kPnnM97M5Ohw8zAGjv83MpxHqfAochH68n/kiXN57+hYaNUCA7XkScoVNr6yzvly3hsY34TGfQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - astro@4.16.16: - resolution: {integrity: sha512-H1CttrV6+JFrDBQx0Mcbq5i5AeLhCbztB786+9wEu3svWL/QPNeCGqF0dgNORAYmP+rODGCPu/y9qKSh87iLuA==} - engines: {node: ^18.17.1 || ^20.3.0 || >=21.0.0, npm: '>=9.6.5', pnpm: '>=7.1.0'} + astro@5.0.3: + resolution: {integrity: sha512-qpeN+POmmfAQu/XDXaI2CxkUgQFwH9uMUVaA1reV9rybzIbOVYc3E3BU5SkiP/W4BMUFPdJtyw6+/n/0AUv6rw==} + engines: {node: ^18.17.1 || ^20.3.0 || >=22.0.0, npm: '>=9.6.5', pnpm: '>=7.1.0'} hasBin: true astrojs-compiler-sync@1.0.1: @@ -2123,19 +2110,11 @@ packages: resolution: {integrity: sha512-/lzGpEWL/8PfI0BmBOPRwp0c/wFNX1RdUML3jK/RcSBA9T8mZDdQpqYBKtCFTOfQbwPqWEOpjqW+Fnayc0969g==} engines: {node: '>=10'} - cli-cursor@5.0.0: - resolution: {integrity: sha512-aCj4O5wKyszjMmDT4tZj93kxyydN/K5zPWSCe6/0AV/AA1pqe5ZBIw0a2ZfPQV7lL5/yb5HsUreJ6UFAF1tEQw==} - engines: {node: '>=18'} - cli-highlight@2.1.11: resolution: {integrity: sha512-9KDcoEVwyUXrjcJNvHD0NFc/hiwe/WPVYIleQh2O1N2Zro5gWJZ/K+3DGn8w8P/F6FxOgzyC5bxDyHIgCSPhGg==} engines: {node: '>=8.0.0', npm: '>=5.0.0'} hasBin: true - cli-spinners@2.9.2: - resolution: {integrity: sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==} - engines: {node: '>=6'} - cli-table3@0.6.5: resolution: {integrity: sha512-+W/5efTR7y5HRD7gACw9yQjqMVvEMLBHmboM/kPWam+H+Hmyrgjh6YncVKK122YZkXrLudzTuAukUw9FnMf7IQ==} engines: {node: 10.* || >= 12.*} @@ -2631,6 +2610,12 @@ packages: jest: optional: true + eslint-plugin-jsdoc@50.6.0: + resolution: {integrity: sha512-tCNp4fR79Le3dYTPB0dKEv7yFyvGkUCa+Z3yuTrrNGGOxBlXo9Pn0PEgroOZikUQOGjxoGMVKNjrOHcYEdfszg==} + engines: {node: '>=18'} + peerDependencies: + eslint: ^7.0.0 || ^8.0.0 || ^9.0.0 + eslint-plugin-jsx-a11y@6.10.2: resolution: {integrity: sha512-scB3nz4WmG75pV8+3eRUQOHZlNSUhFNq37xnpgRkCCELU3XMvXAxLk1eqWWyE22Ki4Q01Fnsw9BA3cJHDPgn2Q==} engines: {node: '>=4.0'} @@ -2779,10 +2764,6 @@ packages: resolution: {integrity: sha512-bFi65yM+xZgk+u/KRIpekdSYkTB5W1pEf0Lt8Q8Msh7b+eQ7LXVtIB1Bkm4fvclDEL1b2CZkMhv2mOeF8tMdkA==} engines: {node: '>=12.0.0'} - extend-shallow@2.0.1: - resolution: {integrity: sha512-zCnTtlxNoAiDc3gqY2aYAWFx7XWWiasuF2K8Me5WbN8otHKTUKBwjPtNpRs/rbUZm7KxWAaNj7P1a/p52GbVug==} - engines: {node: '>=0.10.0'} - extend@3.0.2: resolution: {integrity: sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==} @@ -3019,10 +3000,6 @@ packages: graphemer@1.4.0: resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} - gray-matter@4.0.3: - resolution: {integrity: sha512-5v6yZd4JK3eMI3FqqCouswVqwugaA9r4dNZB1wwcmrD02QkV5H0y7XBQW8QwQqEaZY1pM9aqORSORhJRdNK44Q==} - engines: {node: '>=6.0'} - h3@1.13.0: resolution: {integrity: sha512-vFEAu/yf8UMUcB4s43OaDaigcqpQd14yanmOsn+NcRX3/guSKncyE2rOYhq8RIchgJrPSs/QiIddnTTR1ddiAg==} @@ -3261,10 +3238,6 @@ packages: engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} hasBin: true - is-extendable@0.1.1: - resolution: {integrity: sha512-5BMULNob1vgFX6EjQw5izWDxrecWK9AM72rugNr0TFldMOi0fj6Jk+zeKIt0xGj4cEfQIJth4w3OKWOJ4f+AFw==} - engines: {node: '>=0.10.0'} - is-extglob@2.1.1: resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} engines: {node: '>=0.10.0'} @@ -3289,10 +3262,6 @@ packages: engines: {node: '>=14.16'} hasBin: true - is-interactive@2.0.0: - resolution: {integrity: sha512-qP1vozQRI+BMOPcjFzrjXuQvdak2pHNUMZoeG2eRbiSqyvbEf/wQtEOTOX1guk6E3t36RkaqiSt8A/6YElNxLQ==} - engines: {node: '>=12'} - is-map@2.0.3: resolution: {integrity: sha512-1Qed0/Hr2m+YqxnM09CjA2d/i6YZNfF6R2oRAOj36eUdS6qIV/huPJNSEpKbupewFs+ZsJlxsjjPbc0/afW6Lw==} engines: {node: '>= 0.4'} @@ -3363,10 +3332,6 @@ packages: resolution: {integrity: sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==} engines: {node: '>= 0.4'} - is-unicode-supported@1.3.0: - resolution: {integrity: sha512-43r2mRvz+8JRIKnWJ+3j8JtjRKZ6GmjzfaE/qiBJnikNnYv/6bagRJ1kUhNk8R5EX/GkobD+r+sfxCPJsiKBLQ==} - engines: {node: '>=12'} - is-unicode-supported@2.1.0: resolution: {integrity: sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==} engines: {node: '>=18'} @@ -3502,10 +3467,6 @@ packages: keyv@4.5.4: resolution: {integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==} - kind-of@6.0.3: - resolution: {integrity: sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==} - engines: {node: '>=0.10.0'} - kleur@3.0.3: resolution: {integrity: sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w==} engines: {node: '>=6'} @@ -3521,58 +3482,58 @@ packages: resolution: {integrity: sha512-MbjN408fEndfiQXbFQ1vnd+1NoLDsnQW41410oQBXiyXDMYH5z505juWa4KUE1LqxRC7DgOgZDbKLxHIwm27hA==} engines: {node: '>=0.10'} - lefthook-darwin-arm64@1.8.5: - resolution: {integrity: sha512-BXUcE+2TTkYRGhMB+6HwAbxhK72L4kFKbukb74VfSk9HYBFb/7IQXyUgsB2dik3LSTcDcl9SgOayzeLU9EqmGw==} + lefthook-darwin-arm64@1.9.0: + resolution: {integrity: sha512-pClng2uWTqZ/FBC+YK0O4MlvphtMcw3xnYZYP4mOfM56gkSrMdsoG59AkBWB5zwxQymPiNFyO3H+JJbjvwmueA==} cpu: [arm64] os: [darwin] - lefthook-darwin-x64@1.8.5: - resolution: {integrity: sha512-xkjYwVlJBQiJALR9jJi6MpIF161z6Td3gyVJoGII95h9hETYZV2J7ox4PUGufE5EV8P0AXWveWo8cJWhWVbssw==} + lefthook-darwin-x64@1.9.0: + resolution: {integrity: sha512-PHQHJZHNadWhFan3Vvy24hMYMecR433t0NHODyBgILaZXOmoeMGcQYNHTmOb+R0148BKA/33l00m1CY14ZPqtw==} cpu: [x64] os: [darwin] - lefthook-freebsd-arm64@1.8.5: - resolution: {integrity: sha512-kL8+HxjAtMco824pZkBJiA3+q4djldNNw06atzgAxyy8/Kj+2NjlIaez88NPQHE4hAVMqtURzmRtnaruaRtT1g==} + lefthook-freebsd-arm64@1.9.0: + resolution: {integrity: sha512-yuPJJJ3aDpMihqg1dfS75XgnzUYh+OqSZPmQp49s9RXKAWUCsBiDcirmrseDRbj3WVsatNGQldbV+5F5rNrxqw==} cpu: [arm64] os: [freebsd] - lefthook-freebsd-x64@1.8.5: - resolution: {integrity: sha512-fQfSUbAQVhLalZFl6sFGJQVBJK9EsQpmXrv1Qunhi8QOY/f07a2onsWb+jI9sp31ITTe2Jtzu0h31ZCBqTWxQw==} + lefthook-freebsd-x64@1.9.0: + resolution: {integrity: sha512-7By8mNLsc+EFJJkmeuC8tmYO8+i9oLBqDSHqnlzSNMK8EF5DV9DTAyNIHIbn0OIcwcCe6xBfwLZimeSkKxMZKg==} cpu: [x64] os: [freebsd] - lefthook-linux-arm64@1.8.5: - resolution: {integrity: sha512-gnBonAc3Heq+Sd+MzSbtLmZkYzSDZ+tTpLAfq2Q62qnVEZpWXFd3qfS2up5a7oUEDNcos7OHDqebSbowpNilZA==} + lefthook-linux-arm64@1.9.0: + resolution: {integrity: sha512-MYZD6j+ufryhENqjZe6POD3rT/0LFLfRtK4ddKKEqPGEy5wKpmXjt3ydfqTg6XAFzm6pyQO1zgwPuF40s5r3wQ==} cpu: [arm64] os: [linux] - lefthook-linux-x64@1.8.5: - resolution: {integrity: sha512-lLsbnXy58Syw6VMJS554HbfrBKUZ0mBWvDbr0DGoDBvFyxtvv5kFMbF/ZlRpLKl7Ds9IqCCCW0NpsjsixX4Z+A==} + lefthook-linux-x64@1.9.0: + resolution: {integrity: sha512-xKh5/Lhjn7oI9AmUhtcArS1Y6RjDcxn0KKXAKURhwwZNFI0HGlusIYAF9U86MDqSPbfvEv+nRpq2i6au6Xp6Aw==} cpu: [x64] os: [linux] - lefthook-openbsd-arm64@1.8.5: - resolution: {integrity: sha512-g3XFw/0q0T0Zd1vpPCO5l+ryFIyf+v/FFVPVb6HKvpDI4BYLFVzsZeVGzRiWZt1oJ0DI9qrrvdG4uJJBs4tSDQ==} + lefthook-openbsd-arm64@1.9.0: + resolution: {integrity: sha512-+3YNG0BVWO3CxBfO5GIDU31EWLZgfPU4M/NDqPekIBf8EUSiToXk9D4MNBAYnjjAfAezV/sdDeLm2Jg4l468UQ==} cpu: [arm64] os: [openbsd] - lefthook-openbsd-x64@1.8.5: - resolution: {integrity: sha512-GmfnPUMMxa/ckHS2L7zIobWusaUmDWZU0zQj016QXGYS4SN8l5ZRU/ht4Tg6bbQSO6HYhWcyfIXB1XjPJPpG7w==} + lefthook-openbsd-x64@1.9.0: + resolution: {integrity: sha512-7DGR8oAa5N4JJ1s0hpDJMQ7AUAT3bDNcTPCFw2keVlmg29qMdIL4RIEbVau/DZ8GvZhzoOE8ddtgUH07PeUjRw==} cpu: [x64] os: [openbsd] - lefthook-windows-arm64@1.8.5: - resolution: {integrity: sha512-e+6QAYD7PCsfVtPtnOMSC8PUiwnLCE9xCZq+dIK65/W/Ow84lSzHBR67Wl5MI3RiiGF2g8kulG+U1YZobXbdxQ==} + lefthook-windows-arm64@1.9.0: + resolution: {integrity: sha512-t7LtUL3eDuprxomtuw74KBLXC+Clk1e/L+ofLy4Jw9t0FNPkFDouQv31IQ0HfS5d1aymNKjK/qbm+IOs1XZC6Q==} cpu: [arm64] os: [win32] - lefthook-windows-x64@1.8.5: - resolution: {integrity: sha512-NPZwHbSWuGmYe5EEjkQbvRaotPW9/maKK7kexqrHxjzL/mOaoHSEYlW6ByPz2RB+bvgoTCkNRXlPiDDoDSYv+w==} + lefthook-windows-x64@1.9.0: + resolution: {integrity: sha512-q3L6tXUxicqiVbquyUIVuGlZo3fJ2y4HhgjINYVCRR+kdn+yqu5pR7Vre/I+LnWtm6V6CUmoV2rxx1fl/1lP1w==} cpu: [x64] os: [win32] - lefthook@1.8.5: - resolution: {integrity: sha512-agsAaXJWoM9vOSVmKVYGPYT5IEzz4Upz0yWRva4L0mT+eObcesIrcMCnLLM+iGfweqC5exfDMm7BHUjTwoiGPg==} + lefthook@1.9.0: + resolution: {integrity: sha512-JF2J4+IEsWpTL2NRWXqUzNu3Nf0pfxMd+Io3kXm6rTQ04jpwh06f37VB5lc5L76kgxpjiBiuFoRlPOAY2je3YA==} hasBin: true levn@0.4.1: @@ -3663,10 +3624,6 @@ packages: lodash@4.17.21: resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} - log-symbols@6.0.0: - resolution: {integrity: sha512-i24m8rpwhmPIS4zscNzK6MSEhk0DUWa/8iYQWxhffV8jkI4Phvs3F+quL5xvS0gdQR0FyTCMMH33Y78dDTzzIw==} - engines: {node: '>=18'} - longest-streak@3.1.0: resolution: {integrity: sha512-9Ri+o0JYgehTaVBBDoMqIl8GXtbWg711O3srftcHhZ0dqnETqLaoIK0x17fUw9rFSlK/0NlsKe0Ahhyl5pXE2g==} @@ -3874,10 +3831,6 @@ packages: resolution: {integrity: sha512-vqiC06CuhBTUdZH+RYl8sFrL096vA45Ok5ISO6sE/Mr1jRbGH4Csnhi8f3wKVl7x8mO4Au7Ir9D3Oyv1VYMFJw==} engines: {node: '>=12'} - mimic-function@5.0.1: - resolution: {integrity: sha512-VP79XUPxV2CigYP3jWwAUFSku2aKqBH7uTAapFWCBqutsbmDo96KY5o8uh6U+/YSIn5OxJnXp73beVkpqMIGhA==} - engines: {node: '>=18'} - min-indent@1.0.1: resolution: {integrity: sha512-I9jwMn07Sy/IwOj3zVkVik2JTvgpaykDZEigL6Rx6N9LbMywwUSMtxET+7lVoDLLd3O3IXwJwvuuns8UB/HeAg==} engines: {node: '>=4'} @@ -3934,16 +3887,16 @@ packages: nerf-dart@1.0.0: resolution: {integrity: sha512-EZSPZB70jiVsivaBLYDCyntd5eH8NTSMOn3rB+HxwdmKThGELLdYv8qVIMWvZEFy9w8ZZpW9h9OB32l1rGtj7g==} - next@15.0.3: - resolution: {integrity: sha512-ontCbCRKJUIoivAdGB34yCaOcPgYXr9AAkV/IwqFfWWTXEPUgLYkSkqBhIk9KK7gGmgjc64B+RdoeIDM13Irnw==} + next@15.0.4: + resolution: {integrity: sha512-nuy8FH6M1FG0lktGotamQDCXhh5hZ19Vo0ht1AOIQWrYJLP598TIUagKtvJrfJ5AGwB/WmDqkKaKhMpVifvGPA==} engines: {node: ^18.18.0 || ^19.8.0 || >= 20.0.0} hasBin: true peerDependencies: '@opentelemetry/api': ^1.1.0 '@playwright/test': ^1.41.2 babel-plugin-react-compiler: '*' - react: ^18.2.0 || 19.0.0-rc-66855b96-20241106 - react-dom: ^18.2.0 || 19.0.0-rc-66855b96-20241106 + react: ^18.2.0 || 19.0.0-rc-66855b96-20241106 || ^19.0.0 + react-dom: ^18.2.0 || 19.0.0-rc-66855b96-20241106 || ^19.0.0 sass: ^1.3.0 peerDependenciesMeta: '@opentelemetry/api': @@ -4104,10 +4057,6 @@ packages: resolution: {integrity: sha512-1FlR+gjXK7X+AsAHso35MnyN5KqGwJRi/31ft6x0M194ht7S+rWAvd7PHss9xSKMzE0asv1pyIHaJYq+BbacAQ==} engines: {node: '>=12'} - onetime@7.0.0: - resolution: {integrity: sha512-VXJjc87FScF88uafS3JllDgvAm+c/Slfz06lorj2uAY34rlUu0Nt+v8wreiImcrgAjjIHp1rXpTDlLOGw29WwQ==} - engines: {node: '>=18'} - oniguruma-to-es@0.7.0: resolution: {integrity: sha512-HRaRh09cE0gRS3+wi2zxekB+I5L8C/gN60S+vb11eADHUaB/q4u8wGGOX3GvwvitG8ixaeycZfeoyruKQzUgNg==} @@ -4123,10 +4072,6 @@ packages: resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==} engines: {node: '>= 0.8.0'} - ora@8.1.1: - resolution: {integrity: sha512-YWielGi1XzG1UTvOaCFaNgEnuhZVMSHYkW/FQ7UX8O26PtlpdM84c0f7wLPlkvx2RfiQmnzd61d/MGxmpQeJPw==} - engines: {node: '>=18'} - p-each-series@3.0.0: resolution: {integrity: sha512-lastgtAdoH9YaLyDa5i5z64q+kzOcQHsQ5SsZJD3q0VEyI8mq872S3geuNbRUQLVAE9siMfgKrpj7MloKFHruw==} engines: {node: '>=12'} @@ -4210,6 +4155,10 @@ packages: resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} engines: {node: '>=6'} + parse-imports@2.2.1: + resolution: {integrity: sha512-OL/zLggRp8mFhKL0rNORUTR4yBYujK/uU+xZL+/0Rgm2QE4nLO9v8PzEweSJEbMGKmDRjJE4R3IMJlL2di4JeQ==} + engines: {node: '>= 18'} + parse-json@4.0.0: resolution: {integrity: sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw==} engines: {node: '>=4'} @@ -4616,10 +4565,6 @@ packages: resolution: {integrity: sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==} hasBin: true - restore-cursor@5.1.0: - resolution: {integrity: sha512-oMA2dcrw6u0YfxJQXm342bFKX/E4sG9rbTzO9ptUcR/e8A33cHuvStiYOwH7fszkZlZ1z/ta9AAoPk2F4qIOHA==} - engines: {node: '>=18'} - retext-latin@4.0.0: resolution: {integrity: sha512-hv9woG7Fy0M9IlRQloq/N6atV82NxLGveq+3H2WOi79dtIYWN8OaxogDm77f8YnVXJL2VD3bbqowu5E3EMhBYA==} @@ -4677,10 +4622,6 @@ packages: resolution: {integrity: sha512-3A6sD0WYP7+QrjbfNA2FN3FsOaGGFoekCVgTyypy53gPxhbkCIjtO6YWgdrfM+n/8sI8JeXZOIxsHjMTNxQ4nQ==} engines: {node: ^14.0.0 || >=16.0.0} - section-matter@1.0.0: - resolution: {integrity: sha512-vfD3pmTzGpufjScBh50YHKzEu2lxBWhVEHsNGoEXmCmn2hKGfeNLYMzCJpe8cD7gqX7TJluOVpBkAequ6dgMmA==} - engines: {node: '>=4'} - semantic-release@24.2.0: resolution: {integrity: sha512-fQfn6e/aYToRtVJYKqneFM1Rg3KP2gh3wSWtpYsLlz6uaPKlISrTzvYAFn+mYWo07F0X1Cz5ucU89AVE8X1mbg==} engines: {node: '>=20.8.1'} @@ -4766,6 +4707,9 @@ packages: resolution: {integrity: sha512-ZA6oR3T/pEyuqwMgAKT0/hAv8oAXckzbkmR0UkUosQ+Mc4RxGoJkRmwHgHufaenlyAgE1Mxgpdcrf75y6XcnDg==} engines: {node: '>=14.16'} + slashes@3.0.12: + resolution: {integrity: sha512-Q9VME8WyGkc7pJf6QEkj3wE+2CnvZMI+XJhwdTPR8Z/kWQRXi7boAWLDibRPyHRTUTPx5FaU7MsyrjI3yLB4HA==} + source-map-js@1.2.1: resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} engines: {node: '>=0.10.0'} @@ -4789,6 +4733,9 @@ packages: spdx-expression-parse@3.0.1: resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==} + spdx-expression-parse@4.0.0: + resolution: {integrity: sha512-Clya5JIij/7C6bRR22+tnGXbc4VKlibKSVj2iHvVeX5iMW7s1SIQlqu699JkODJJIhh/pUu8L0/VLh8xflD+LQ==} + spdx-license-ids@3.0.20: resolution: {integrity: sha512-jg25NiDV/1fLtSgEgyvVyDunvaNHbuwF9lfNV17gSmPFAlYzdfNBlLtLzXTevwkPj7DhGbmN9VnmJIgLnhvaBw==} @@ -4811,10 +4758,6 @@ packages: std-env@3.8.0: resolution: {integrity: sha512-Bc3YwwCB+OzldMxOXJIIvC6cPRWr/LxOp48CdQTOkPyk/t4JWWJbrilwBd7RJzKV8QW7tJkcgAmeuLLJugl5/w==} - stdin-discarder@0.2.2: - resolution: {integrity: sha512-UhDfHmA92YAlNnCfhmq0VeNL5bDbiZGg7sZ2IvPsXubGkiNa9EC+tUTsjBRsYUAz87btI6/1wf4XoVvQ3uRnmQ==} - engines: {node: '>=18'} - storybook@8.4.7: resolution: {integrity: sha512-RP/nMJxiWyFc8EVMH5gp20ID032Wvk+Yr3lmKidoegto5Iy+2dVQnUoElZb2zpbVXNHWakGuAkfI0dY1Hfp/vw==} hasBin: true @@ -4879,10 +4822,6 @@ packages: resolution: {integrity: sha512-iq6eVVI64nQQTRYq2KtEg2d2uU7LElhTJwsH4YzIHZshxlgZms/wIc4VoDQTlG/IvVIrBKG06CrZnp0qv7hkcQ==} engines: {node: '>=12'} - strip-bom-string@1.0.0: - resolution: {integrity: sha512-uCC2VHvQRYu+lMh4My/sFNmF2klFymLX1wHJeXnbEJERpV/ZsVuonzerjfrGpIGF7LBVa1O7i9kjiWvJiFck8g==} - engines: {node: '>=0.10.0'} - strip-bom@3.0.0: resolution: {integrity: sha512-vavAMRXOgBVNF6nyEEmL3DBK19iRpDcoIwW+swQ+CbGiu7lju6t+JklA1MHweoWtadgt4ISVUsXLyDq34ddcwA==} engines: {node: '>=4'} @@ -5122,6 +5061,9 @@ packages: engines: {node: '>=0.8.0'} hasBin: true + ultrahtml@1.5.3: + resolution: {integrity: sha512-GykOvZwgDWZlTQMtp5jrD4BVL+gNn2NVlVafjcFUJ7taY20tqYdwdoWBFy6GBJsNTZe1GkGPkSl5knQAjtgceg==} + unbox-primitive@1.0.2: resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} @@ -5254,6 +5196,46 @@ packages: terser: optional: true + vite@6.0.3: + resolution: {integrity: sha512-Cmuo5P0ENTN6HxLSo6IHsjCLn/81Vgrp81oaiFFMRa8gGDj5xEjIcEpf2ZymZtZR8oU0P2JX5WuUp/rlXcHkAw==} + engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} + hasBin: true + peerDependencies: + '@types/node': ^18.0.0 || ^20.0.0 || >=22.0.0 + jiti: '>=1.21.0' + less: '*' + lightningcss: ^1.21.0 + sass: '*' + sass-embedded: '*' + stylus: '*' + sugarss: '*' + terser: ^5.16.0 + tsx: ^4.8.1 + yaml: ^2.4.2 + peerDependenciesMeta: + '@types/node': + optional: true + jiti: + optional: true + less: + optional: true + lightningcss: + optional: true + sass: + optional: true + sass-embedded: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + tsx: + optional: true + yaml: + optional: true + vitefu@1.0.4: resolution: {integrity: sha512-y6zEE3PQf6uu/Mt6DTJ9ih+kyJLr4XcSgHR2zUkM8SWDhuixEJxfJ6CZGMHh1Ec3vPLoEA0IHU5oWzVqw8ulow==} peerDependencies: @@ -5405,6 +5387,10 @@ packages: resolution: {integrity: sha512-b4JR1PFR10y1mKjhHY9LaGo6tmrgjit7hxVIeAmyMw3jegXR4dhYqLaQF5zMXZxY7tLpMyJeLjr1C4rLmkVe8g==} engines: {node: '>=12.20'} + yocto-spinner@0.1.1: + resolution: {integrity: sha512-vb6yztJdmbX9BwiR2NlKim7roGM5xFFhiTO6UstNiKBnh8NT6uFNjpXYC6DWTnLgRRyHh2nDNEM8kLHSRLw4kg==} + engines: {node: '>=18.19'} + yoctocolors@2.1.1: resolution: {integrity: sha512-GQHQqAopRhwU8Kt1DDM8NjibDXHC8eoh1erhGAJPEyveY9qqVeXvVikNKrDz69sHowPMorbPUrH/mx8c50eiBQ==} engines: {node: '>=18'} @@ -5447,15 +5433,16 @@ snapshots: '@astrojs/compiler@2.10.3': {} - '@astrojs/internal-helpers@0.4.1': {} + '@astrojs/internal-helpers@0.4.2': {} - '@astrojs/markdown-remark@5.3.0': + '@astrojs/markdown-remark@6.0.0': dependencies: - '@astrojs/prism': 3.1.0 + '@astrojs/prism': 3.2.0 github-slugger: 2.0.0 hast-util-from-html: 2.0.3 hast-util-to-text: 4.0.2 import-meta-resolve: 4.1.0 + js-yaml: 4.1.0 mdast-util-definitions: 6.0.0 rehype-raw: 7.0.0 rehype-stringify: 10.0.1 @@ -5472,11 +5459,11 @@ snapshots: transitivePeerDependencies: - supports-color - '@astrojs/prism@3.1.0': + '@astrojs/prism@3.2.0': dependencies: prismjs: 1.29.0 - '@astrojs/telemetry@3.1.0': + '@astrojs/telemetry@3.2.0': dependencies: ci-info: 4.1.0 debug: 4.3.7 @@ -5609,11 +5596,6 @@ snapshots: dependencies: '@babel/types': 7.26.0 - '@babel/plugin-syntax-jsx@7.25.9(@babel/core@7.26.0)': - dependencies: - '@babel/core': 7.26.0 - '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-transform-private-methods@7.25.9(@babel/core@7.26.0)': dependencies: '@babel/core': 7.26.0 @@ -5622,17 +5604,6 @@ snapshots: transitivePeerDependencies: - supports-color - '@babel/plugin-transform-react-jsx@7.25.9(@babel/core@7.26.0)': - dependencies: - '@babel/core': 7.26.0 - '@babel/helper-annotate-as-pure': 7.25.9 - '@babel/helper-module-imports': 7.25.9 - '@babel/helper-plugin-utils': 7.25.9 - '@babel/plugin-syntax-jsx': 7.25.9(@babel/core@7.26.0) - '@babel/types': 7.26.0 - transitivePeerDependencies: - - supports-color - '@babel/runtime@7.26.0': dependencies: regenerator-runtime: 0.14.1 @@ -5780,6 +5751,12 @@ snapshots: tslib: 2.8.1 optional: true + '@es-joy/jsdoccomment@0.49.0': + dependencies: + comment-parser: 1.4.1 + esquery: 1.6.0 + jsdoc-type-pratt-parser: 4.1.0 + '@esbuild/aix-ppc64@0.21.5': optional: true @@ -6210,34 +6187,34 @@ snapshots: '@jsdevtools/ono@7.1.3': {} - '@next/env@15.0.3': {} + '@next/env@15.0.4': {} '@next/eslint-plugin-next@15.0.3': dependencies: fast-glob: 3.3.1 - '@next/swc-darwin-arm64@15.0.3': + '@next/swc-darwin-arm64@15.0.4': optional: true - '@next/swc-darwin-x64@15.0.3': + '@next/swc-darwin-x64@15.0.4': optional: true - '@next/swc-linux-arm64-gnu@15.0.3': + '@next/swc-linux-arm64-gnu@15.0.4': optional: true - '@next/swc-linux-arm64-musl@15.0.3': + '@next/swc-linux-arm64-musl@15.0.4': optional: true - '@next/swc-linux-x64-gnu@15.0.3': + '@next/swc-linux-x64-gnu@15.0.4': optional: true - '@next/swc-linux-x64-musl@15.0.3': + '@next/swc-linux-x64-musl@15.0.4': optional: true - '@next/swc-win32-arm64-msvc@15.0.3': + '@next/swc-win32-arm64-msvc@15.0.4': optional: true - '@next/swc-win32-x64-msvc@15.0.3': + '@next/swc-win32-x64-msvc@15.0.4': optional: true '@nodelib/fs.scandir@2.1.5': @@ -6689,11 +6666,11 @@ snapshots: - supports-color - typescript - '@tanstack/query-core@5.62.2': {} + '@tanstack/query-core@5.62.3': {} - '@tanstack/react-query@5.62.2(react@18.3.1)': + '@tanstack/react-query@5.62.3(react@18.3.1)': dependencies: - '@tanstack/query-core': 5.62.2 + '@tanstack/query-core': 5.62.3 react: 18.3.1 '@testing-library/dom@10.4.0': @@ -6720,27 +6697,6 @@ snapshots: '@types/aria-query@5.0.4': {} - '@types/babel__core@7.20.5': - dependencies: - '@babel/parser': 7.26.2 - '@babel/types': 7.26.0 - '@types/babel__generator': 7.6.8 - '@types/babel__template': 7.4.4 - '@types/babel__traverse': 7.20.6 - - '@types/babel__generator@7.6.8': - dependencies: - '@babel/types': 7.26.0 - - '@types/babel__template@7.4.4': - dependencies: - '@babel/parser': 7.26.2 - '@babel/types': 7.26.0 - - '@types/babel__traverse@7.20.6': - dependencies: - '@babel/types': 7.26.0 - '@types/conventional-commits-parser@5.0.0': dependencies: '@types/node': 22.10.1 @@ -7056,6 +7012,8 @@ snapshots: any-promise@1.3.0: {} + are-docs-informative@0.0.2: {} + argparse@1.0.10: dependencies: sprintf-js: 1.0.3 @@ -7159,18 +7117,14 @@ snapshots: - supports-color - typescript - astro@4.16.16(@types/node@22.10.1)(rollup@4.27.2)(typescript@5.7.2): + astro@5.0.3(@types/node@22.10.1)(jiti@2.4.1)(rollup@4.27.2)(tsx@4.19.2)(typescript@5.7.2)(yaml@2.6.0): dependencies: '@astrojs/compiler': 2.10.3 - '@astrojs/internal-helpers': 0.4.1 - '@astrojs/markdown-remark': 5.3.0 - '@astrojs/telemetry': 3.1.0 - '@babel/core': 7.26.0 - '@babel/plugin-transform-react-jsx': 7.25.9(@babel/core@7.26.0) - '@babel/types': 7.26.0 + '@astrojs/internal-helpers': 0.4.2 + '@astrojs/markdown-remark': 6.0.0 + '@astrojs/telemetry': 3.2.0 '@oslojs/encoding': 1.1.0 '@rollup/pluginutils': 5.1.3(rollup@4.27.2) - '@types/babel__core': 7.20.5 '@types/cookie': 0.6.0 acorn: 8.14.0 aria-query: 5.3.2 @@ -7193,7 +7147,6 @@ snapshots: fast-glob: 3.3.2 flattie: 1.1.1 github-slugger: 2.0.0 - gray-matter: 4.0.3 html-escaper: 3.0.3 http-cache-semantics: 4.1.1 js-yaml: 4.1.0 @@ -7203,7 +7156,6 @@ snapshots: micromatch: 4.0.8 mrmime: 2.0.0 neotraverse: 0.6.18 - ora: 8.1.1 p-limit: 6.1.0 p-queue: 8.0.1 preferred-pm: 4.0.0 @@ -7213,13 +7165,15 @@ snapshots: shiki: 1.24.0 tinyexec: 0.3.1 tsconfck: 3.1.4(typescript@5.7.2) + ultrahtml: 1.5.3 unist-util-visit: 5.0.0 vfile: 6.0.3 - vite: 5.4.11(@types/node@22.10.1) - vitefu: 1.0.4(vite@5.4.11(@types/node@22.10.1)) + vite: 6.0.3(@types/node@22.10.1)(jiti@2.4.1)(tsx@4.19.2)(yaml@2.6.0) + vitefu: 1.0.4(vite@6.0.3(@types/node@22.10.1)(jiti@2.4.1)(tsx@4.19.2)(yaml@2.6.0)) which-pm: 3.0.0 xxhash-wasm: 1.1.0 yargs-parser: 21.1.1 + yocto-spinner: 0.1.1 zod: 3.23.8 zod-to-json-schema: 3.23.5(zod@3.23.8) zod-to-ts: 1.2.0(typescript@5.7.2)(zod@3.23.8) @@ -7227,6 +7181,7 @@ snapshots: sharp: 0.33.5 transitivePeerDependencies: - '@types/node' + - jiti - less - lightningcss - rollup @@ -7236,7 +7191,9 @@ snapshots: - sugarss - supports-color - terser + - tsx - typescript + - yaml astrojs-compiler-sync@1.0.1(@astrojs/compiler@2.10.3): dependencies: @@ -7384,10 +7341,6 @@ snapshots: cli-boxes@3.0.0: {} - cli-cursor@5.0.0: - dependencies: - restore-cursor: 5.1.0 - cli-highlight@2.1.11: dependencies: chalk: 4.1.2 @@ -7397,8 +7350,6 @@ snapshots: parse5-htmlparser2-tree-adapter: 6.0.1 yargs: 16.2.0 - cli-spinners@2.9.2: {} - cli-table3@0.6.5: dependencies: string-width: 4.2.3 @@ -8002,6 +7953,23 @@ snapshots: - supports-color - typescript + eslint-plugin-jsdoc@50.6.0(eslint@9.16.0(jiti@2.4.1)): + dependencies: + '@es-joy/jsdoccomment': 0.49.0 + are-docs-informative: 0.0.2 + comment-parser: 1.4.1 + debug: 4.3.7 + escape-string-regexp: 4.0.0 + eslint: 9.16.0(jiti@2.4.1) + espree: 10.3.0 + esquery: 1.6.0 + parse-imports: 2.2.1 + semver: 7.6.3 + spdx-expression-parse: 4.0.0 + synckit: 0.9.2 + transitivePeerDependencies: + - supports-color + eslint-plugin-jsx-a11y@6.10.2(eslint@9.16.0(jiti@2.4.1)): dependencies: aria-query: 5.3.2 @@ -8265,10 +8233,6 @@ snapshots: expect-type@1.1.0: {} - extend-shallow@2.0.1: - dependencies: - is-extendable: 0.1.1 - extend@3.0.2: {} fast-deep-equal@3.1.3: {} @@ -8522,13 +8486,6 @@ snapshots: graphemer@1.4.0: {} - gray-matter@4.0.3: - dependencies: - js-yaml: 3.14.1 - kind-of: 6.0.3 - section-matter: 1.0.0 - strip-bom-string: 1.0.0 - h3@1.13.0: dependencies: cookie-es: 1.2.2 @@ -8809,8 +8766,6 @@ snapshots: is-docker@3.0.0: {} - is-extendable@0.1.1: {} - is-extglob@2.1.1: {} is-finalizationregistry@1.0.2: @@ -8831,8 +8786,6 @@ snapshots: dependencies: is-docker: 3.0.0 - is-interactive@2.0.0: {} - is-map@2.0.3: {} is-module@1.0.0: {} @@ -8886,8 +8839,6 @@ snapshots: dependencies: which-typed-array: 1.1.15 - is-unicode-supported@1.3.0: {} - is-unicode-supported@2.1.0: {} is-weakmap@2.0.2: {} @@ -9019,8 +8970,6 @@ snapshots: dependencies: json-buffer: 3.0.1 - kind-of@6.0.3: {} - kleur@3.0.3: {} kleur@4.1.5: {} @@ -9031,48 +8980,48 @@ snapshots: dependencies: language-subtag-registry: 0.3.23 - lefthook-darwin-arm64@1.8.5: + lefthook-darwin-arm64@1.9.0: optional: true - lefthook-darwin-x64@1.8.5: + lefthook-darwin-x64@1.9.0: optional: true - lefthook-freebsd-arm64@1.8.5: + lefthook-freebsd-arm64@1.9.0: optional: true - lefthook-freebsd-x64@1.8.5: + lefthook-freebsd-x64@1.9.0: optional: true - lefthook-linux-arm64@1.8.5: + lefthook-linux-arm64@1.9.0: optional: true - lefthook-linux-x64@1.8.5: + lefthook-linux-x64@1.9.0: optional: true - lefthook-openbsd-arm64@1.8.5: + lefthook-openbsd-arm64@1.9.0: optional: true - lefthook-openbsd-x64@1.8.5: + lefthook-openbsd-x64@1.9.0: optional: true - lefthook-windows-arm64@1.8.5: + lefthook-windows-arm64@1.9.0: optional: true - lefthook-windows-x64@1.8.5: + lefthook-windows-x64@1.9.0: optional: true - lefthook@1.8.5: + lefthook@1.9.0: optionalDependencies: - lefthook-darwin-arm64: 1.8.5 - lefthook-darwin-x64: 1.8.5 - lefthook-freebsd-arm64: 1.8.5 - lefthook-freebsd-x64: 1.8.5 - lefthook-linux-arm64: 1.8.5 - lefthook-linux-x64: 1.8.5 - lefthook-openbsd-arm64: 1.8.5 - lefthook-openbsd-x64: 1.8.5 - lefthook-windows-arm64: 1.8.5 - lefthook-windows-x64: 1.8.5 + lefthook-darwin-arm64: 1.9.0 + lefthook-darwin-x64: 1.9.0 + lefthook-freebsd-arm64: 1.9.0 + lefthook-freebsd-x64: 1.9.0 + lefthook-linux-arm64: 1.9.0 + lefthook-linux-x64: 1.9.0 + lefthook-openbsd-arm64: 1.9.0 + lefthook-openbsd-x64: 1.9.0 + lefthook-windows-arm64: 1.9.0 + lefthook-windows-x64: 1.9.0 levn@0.4.1: dependencies: @@ -9151,11 +9100,6 @@ snapshots: lodash@4.17.21: {} - log-symbols@6.0.0: - dependencies: - chalk: 5.3.0 - is-unicode-supported: 1.3.0 - longest-streak@3.1.0: {} loose-envify@1.4.0: @@ -9537,8 +9481,6 @@ snapshots: mimic-fn@4.0.0: {} - mimic-function@5.0.1: {} - min-indent@1.0.1: {} minimatch@3.1.2: @@ -9589,9 +9531,9 @@ snapshots: nerf-dart@1.0.0: {} - next@15.0.3(@babel/core@7.26.0)(@playwright/test@1.49.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): + next@15.0.4(@playwright/test@1.49.0)(react-dom@18.3.1(react@18.3.1))(react@18.3.1): dependencies: - '@next/env': 15.0.3 + '@next/env': 15.0.4 '@swc/counter': 0.1.3 '@swc/helpers': 0.5.13 busboy: 1.6.0 @@ -9599,16 +9541,16 @@ snapshots: postcss: 8.4.31 react: 18.3.1 react-dom: 18.3.1(react@18.3.1) - styled-jsx: 5.1.6(@babel/core@7.26.0)(react@18.3.1) + styled-jsx: 5.1.6(react@18.3.1) optionalDependencies: - '@next/swc-darwin-arm64': 15.0.3 - '@next/swc-darwin-x64': 15.0.3 - '@next/swc-linux-arm64-gnu': 15.0.3 - '@next/swc-linux-arm64-musl': 15.0.3 - '@next/swc-linux-x64-gnu': 15.0.3 - '@next/swc-linux-x64-musl': 15.0.3 - '@next/swc-win32-arm64-msvc': 15.0.3 - '@next/swc-win32-x64-msvc': 15.0.3 + '@next/swc-darwin-arm64': 15.0.4 + '@next/swc-darwin-x64': 15.0.4 + '@next/swc-linux-arm64-gnu': 15.0.4 + '@next/swc-linux-arm64-musl': 15.0.4 + '@next/swc-linux-x64-gnu': 15.0.4 + '@next/swc-linux-x64-musl': 15.0.4 + '@next/swc-win32-arm64-msvc': 15.0.4 + '@next/swc-win32-x64-msvc': 15.0.4 '@playwright/test': 1.49.0 sharp: 0.33.5 transitivePeerDependencies: @@ -9702,10 +9644,6 @@ snapshots: dependencies: mimic-fn: 4.0.0 - onetime@7.0.0: - dependencies: - mimic-function: 5.0.1 - oniguruma-to-es@0.7.0: dependencies: emoji-regex-xs: 1.0.0 @@ -9734,18 +9672,6 @@ snapshots: type-check: 0.4.0 word-wrap: 1.2.5 - ora@8.1.1: - dependencies: - chalk: 5.3.0 - cli-cursor: 5.0.0 - cli-spinners: 2.9.2 - is-interactive: 2.0.0 - is-unicode-supported: 2.1.0 - log-symbols: 6.0.0 - stdin-discarder: 0.2.2 - string-width: 7.2.0 - strip-ansi: 7.1.0 - p-each-series@3.0.0: {} p-filter@4.1.0: @@ -9813,6 +9739,11 @@ snapshots: dependencies: callsites: 3.1.0 + parse-imports@2.2.1: + dependencies: + es-module-lexer: 1.5.4 + slashes: 3.0.12 + parse-json@4.0.0: dependencies: error-ex: 1.3.2 @@ -10219,11 +10150,6 @@ snapshots: path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 - restore-cursor@5.1.0: - dependencies: - onetime: 7.0.0 - signal-exit: 4.1.0 - retext-latin@4.0.0: dependencies: '@types/nlcst': 2.0.3 @@ -10336,11 +10262,6 @@ snapshots: refa: 0.12.1 regexp-ast-analysis: 0.7.1 - section-matter@1.0.0: - dependencies: - extend-shallow: 2.0.1 - kind-of: 6.0.3 - semantic-release@24.2.0(typescript@5.7.2): dependencies: '@semantic-release/commit-analyzer': 13.0.0(semantic-release@24.2.0(typescript@5.7.2)) @@ -10480,6 +10401,8 @@ snapshots: slash@5.1.0: {} + slashes@3.0.12: {} + source-map-js@1.2.1: {} source-map@0.6.1: {} @@ -10500,6 +10423,11 @@ snapshots: spdx-exceptions: 2.5.0 spdx-license-ids: 3.0.20 + spdx-expression-parse@4.0.0: + dependencies: + spdx-exceptions: 2.5.0 + spdx-license-ids: 3.0.20 + spdx-license-ids@3.0.20: {} split2@1.0.0: @@ -10516,8 +10444,6 @@ snapshots: std-env@3.8.0: {} - stdin-discarder@0.2.2: {} - storybook@8.4.7(prettier@3.4.2): dependencies: '@storybook/core': 8.4.7(prettier@3.4.2) @@ -10615,8 +10541,6 @@ snapshots: dependencies: ansi-regex: 6.1.0 - strip-bom-string@1.0.0: {} - strip-bom@3.0.0: {} strip-final-newline@2.0.0: {} @@ -10633,12 +10557,10 @@ snapshots: strip-json-comments@3.1.1: {} - styled-jsx@5.1.6(@babel/core@7.26.0)(react@18.3.1): + styled-jsx@5.1.6(react@18.3.1): dependencies: client-only: 0.0.1 react: 18.3.1 - optionalDependencies: - '@babel/core': 7.26.0 suf-log@2.5.3: dependencies: @@ -10816,6 +10738,8 @@ snapshots: uglify-js@3.19.3: optional: true + ultrahtml@1.5.3: {} + unbox-primitive@1.0.2: dependencies: call-bind: 1.0.7 @@ -10970,9 +10894,21 @@ snapshots: '@types/node': 22.10.1 fsevents: 2.3.3 - vitefu@1.0.4(vite@5.4.11(@types/node@22.10.1)): + vite@6.0.3(@types/node@22.10.1)(jiti@2.4.1)(tsx@4.19.2)(yaml@2.6.0): + dependencies: + esbuild: 0.24.0 + postcss: 8.4.49 + rollup: 4.27.2 + optionalDependencies: + '@types/node': 22.10.1 + fsevents: 2.3.3 + jiti: 2.4.1 + tsx: 4.19.2 + yaml: 2.6.0 + + vitefu@1.0.4(vite@6.0.3(@types/node@22.10.1)(jiti@2.4.1)(tsx@4.19.2)(yaml@2.6.0)): optionalDependencies: - vite: 5.4.11(@types/node@22.10.1) + vite: 6.0.3(@types/node@22.10.1)(jiti@2.4.1)(tsx@4.19.2)(yaml@2.6.0) vitest@2.1.8(@types/node@22.10.1): dependencies: @@ -11138,6 +11074,10 @@ snapshots: yocto-queue@1.1.1: {} + yocto-spinner@0.1.1: + dependencies: + yoctocolors: 2.1.1 + yoctocolors@2.1.1: {} zod-to-json-schema@3.23.5(zod@3.23.8): diff --git a/src/configs/jsdoc.ts b/src/configs/jsdoc.ts new file mode 100644 index 0000000..ebfb512 --- /dev/null +++ b/src/configs/jsdoc.ts @@ -0,0 +1,13 @@ +import jsdocPlugin from "eslint-plugin-jsdoc"; + +import { jsdocRules } from "../rules/jsdoc"; + +export const jsdocConfig = () => { + return [ + { + ...jsdocPlugin.configs["flat/recommended-typescript-error"], + name: "jimmy.codes/jsdoc", + rules: jsdocRules(), + }, + ]; +}; diff --git a/src/factory.spec.ts b/src/factory.spec.ts index b36cb98..ec4c95d 100644 --- a/src/factory.spec.ts +++ b/src/factory.spec.ts @@ -16,6 +16,7 @@ describe("eslintConfig", () => { "ignores", "javascript", "regexp", + "jsdoc", ])("should create configuration w/ %s", async (input) => { await expect(eslintConfig({ autoDetect: false })).resolves.toStrictEqual( expect.arrayContaining([ @@ -63,7 +64,7 @@ describe("eslintConfig", () => { it("should create configuration w/ jest", async () => { const configs = await eslintConfig({ autoDetect: false, jest: true }); - expect(configs.at(7)?.name).toBe("jimmy.codes/jest"); + expect(configs.at(8)?.name).toBe("jimmy.codes/jest"); }); it("should create configuration w/ jest (deprecated)", async () => { @@ -80,7 +81,7 @@ describe("eslintConfig", () => { it("should create configuration w/ vitest", async () => { const configs = await eslintConfig({ autoDetect: false, vitest: true }); - expect(configs.at(7)?.name).toBe("jimmy.codes/vitest"); + expect(configs.at(8)?.name).toBe("jimmy.codes/vitest"); }); it("should create configuration w/ vitest (deprecated)", async () => { @@ -102,9 +103,9 @@ describe("eslintConfig", () => { testingLibrary: true, }); - expect(configs.at(7)?.name).toBe("jimmy.codes/react"); - expect(configs.at(8)?.name).toBe("jimmy.codes/jest"); - expect(configs.at(9)?.name).toBe("jimmy.codes/testing-library"); + expect(configs.at(8)?.name).toBe("jimmy.codes/react"); + expect(configs.at(9)?.name).toBe("jimmy.codes/jest"); + expect(configs.at(10)?.name).toBe("jimmy.codes/testing-library"); }); it("should create configuration w/ jest & react & testing library (deprecated)", async () => { @@ -131,9 +132,9 @@ describe("eslintConfig", () => { vitest: true, }); - expect(configs.at(7)?.name).toBe("jimmy.codes/react"); - expect(configs.at(8)?.name).toBe("jimmy.codes/vitest"); - expect(configs.at(9)?.name).toBe("jimmy.codes/testing-library"); + expect(configs.at(8)?.name).toBe("jimmy.codes/react"); + expect(configs.at(9)?.name).toBe("jimmy.codes/vitest"); + expect(configs.at(10)?.name).toBe("jimmy.codes/testing-library"); }); it("should create configuration w/ vitest & react & testing library (deprecated)", async () => { @@ -186,7 +187,7 @@ describe("eslintConfig", () => { tanstackQuery: true, }); - expect(configs.at(7)?.name).toBe("jimmy.codes/react/query"); + expect(configs.at(8)?.name).toBe("jimmy.codes/react/query"); }); it("should create configuration w/ storybook", async () => { @@ -195,7 +196,7 @@ describe("eslintConfig", () => { storybook: true, }); - expect(configs.at(7)?.name).toBe("jimmy.codes/storybook/setup"); + expect(configs.at(8)?.name).toBe("jimmy.codes/storybook/setup"); }); it("should create configuration w/ nextjs", async () => { @@ -204,7 +205,7 @@ describe("eslintConfig", () => { nextjs: true, }); - expect(configs.at(7)?.name).toBe("jimmy.codes/nextjs"); + expect(configs.at(8)?.name).toBe("jimmy.codes/nextjs"); }); describe("autoDetect", () => { @@ -356,7 +357,7 @@ describe("eslintConfig", () => { autoDetect: true, }); - expect(configs.at(7)?.name).toBe("jimmy.codes/storybook/setup"); + expect(configs.at(8)?.name).toBe("jimmy.codes/storybook/setup"); }); it("should include nextjs when auto detection is enabled", async () => { @@ -368,7 +369,7 @@ describe("eslintConfig", () => { autoDetect: true, }); - expect(configs.at(7)?.name).toBe("jimmy.codes/nextjs"); + expect(configs.at(8)?.name).toBe("jimmy.codes/nextjs"); }); }); }); diff --git a/src/factory.ts b/src/factory.ts index 2903151..60dde7f 100644 --- a/src/factory.ts +++ b/src/factory.ts @@ -8,6 +8,7 @@ import { eslintCommentsConfig } from "./configs/eslint-comments"; import { ignoresConfig } from "./configs/ignores"; import { importsConfig } from "./configs/imports"; import { javascriptConfig } from "./configs/javascript"; +import { jsdocConfig } from "./configs/jsdoc"; import { nextjsConfig } from "./configs/nextjs"; import { nodeConfig } from "./configs/node"; import { perfectionistConfig } from "./configs/perfectionist"; @@ -93,6 +94,7 @@ export const eslintConfig = async ( unicornConfig(), eslintCommentsConfig(), regexpConfig(), + jsdocConfig(), importsConfig({ typescript: isTypescriptEnabled }), isTypescriptEnabled ? typescriptConfig(typescriptOptions) : [], isReactEnabled ? await reactConfig() : [], diff --git a/src/rules.gen.d.ts b/src/rules.gen.d.ts index 9f3dbd5..56ad9f7 100644 --- a/src/rules.gen.d.ts +++ b/src/rules.gen.d.ts @@ -1973,6 +1973,291 @@ export interface RuleOptions { * @see https://github.com/jest-community/eslint-plugin-jest/blob/v28.9.0/docs/rules/valid-title.md */ 'jest/valid-title'?: Linter.RuleEntry + /** + * Checks that `@access` tags have a valid value. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-access.md#repos-sticky-header + */ + 'jsdoc/check-access'?: Linter.RuleEntry<[]> + /** + * Reports invalid alignment of JSDoc block asterisks. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-alignment.md#repos-sticky-header + */ + 'jsdoc/check-alignment'?: Linter.RuleEntry<[]> + /** + * Ensures that (JavaScript) examples within JSDoc adhere to ESLint rules. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-examples.md#repos-sticky-header + */ + 'jsdoc/check-examples'?: Linter.RuleEntry + /** + * Reports invalid padding inside JSDoc blocks. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-indentation.md#repos-sticky-header + */ + 'jsdoc/check-indentation'?: Linter.RuleEntry + /** + * Reports invalid alignment of JSDoc block lines. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-line-alignment.md#repos-sticky-header + */ + 'jsdoc/check-line-alignment'?: Linter.RuleEntry + /** + * Ensures that parameter names in JSDoc match those in the function declaration. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-param-names.md#repos-sticky-header + */ + 'jsdoc/check-param-names'?: Linter.RuleEntry + /** + * Ensures that property names in JSDoc are not duplicated on the same block and that nested properties have defined roots. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-property-names.md#repos-sticky-header + */ + 'jsdoc/check-property-names'?: Linter.RuleEntry + /** + * Reports against syntax not valid for the mode (e.g., Google Closure Compiler in non-Closure mode). + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-syntax.md#repos-sticky-header + */ + 'jsdoc/check-syntax'?: Linter.RuleEntry<[]> + /** + * Reports invalid block tag names. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-tag-names.md#repos-sticky-header + */ + 'jsdoc/check-tag-names'?: Linter.RuleEntry + /** + * Checks that any `@template` names are actually used in the connected `@typedef` or type alias. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-template-names.md#repos-sticky-header + */ + 'jsdoc/check-template-names'?: Linter.RuleEntry<[]> + /** + * Reports invalid types. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-types.md#repos-sticky-header + */ + 'jsdoc/check-types'?: Linter.RuleEntry + /** + * This rule checks the values for a handful of tags: `@version`, `@since`, `@license` and `@author`. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/check-values.md#repos-sticky-header + */ + 'jsdoc/check-values'?: Linter.RuleEntry + /** + * Converts non-JSDoc comments preceding or following nodes into JSDoc ones + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/convert-to-jsdoc-comments.md#repos-sticky-header + */ + 'jsdoc/convert-to-jsdoc-comments'?: Linter.RuleEntry + /** + * Expects specific tags to be empty of any content. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/empty-tags.md#repos-sticky-header + */ + 'jsdoc/empty-tags'?: Linter.RuleEntry + /** + * Reports an issue with any non-constructor function using `@implements`. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/implements-on-classes.md#repos-sticky-header + */ + 'jsdoc/implements-on-classes'?: Linter.RuleEntry + /** + * Reports if JSDoc `import()` statements point to a package which is not listed in `dependencies` or `devDependencies` + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/imports-as-dependencies.md#repos-sticky-header + */ + 'jsdoc/imports-as-dependencies'?: Linter.RuleEntry<[]> + /** + * This rule reports doc comments that only restate their attached name. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/informative-docs.md#repos-sticky-header + */ + 'jsdoc/informative-docs'?: Linter.RuleEntry + /** + * Enforces minimum number of newlines before JSDoc comment blocks + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/lines-before-block.md#repos-sticky-header + */ + 'jsdoc/lines-before-block'?: Linter.RuleEntry + /** + * Enforces a regular expression pattern on descriptions. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/match-description.md#repos-sticky-header + */ + 'jsdoc/match-description'?: Linter.RuleEntry + /** + * Reports the name portion of a JSDoc tag if matching or not matching a given regular expression. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/match-name.md#repos-sticky-header + */ + 'jsdoc/match-name'?: Linter.RuleEntry + /** + * Controls how and whether jsdoc blocks can be expressed as single or multiple line blocks. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/multiline-blocks.md#repos-sticky-header + */ + 'jsdoc/multiline-blocks'?: Linter.RuleEntry + /** + * This rule checks for multi-line-style comments which fail to meet the criteria of a jsdoc block. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-bad-blocks.md#repos-sticky-header + */ + 'jsdoc/no-bad-blocks'?: Linter.RuleEntry + /** + * Detects and removes extra lines of a blank block description + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-blank-block-descriptions.md#repos-sticky-header + */ + 'jsdoc/no-blank-block-descriptions'?: Linter.RuleEntry<[]> + /** + * Removes empty blocks with nothing but possibly line breaks + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-blank-blocks.md#repos-sticky-header + */ + 'jsdoc/no-blank-blocks'?: Linter.RuleEntry + /** + * This rule reports defaults being used on the relevant portion of `@param` or `@default`. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-defaults.md#repos-sticky-header + */ + 'jsdoc/no-defaults'?: Linter.RuleEntry + /** + * Reports when certain comment structures are always expected. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-missing-syntax.md#repos-sticky-header + */ + 'jsdoc/no-missing-syntax'?: Linter.RuleEntry + /** + * Prevents use of multiple asterisks at the beginning of lines. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-multi-asterisks.md#repos-sticky-header + */ + 'jsdoc/no-multi-asterisks'?: Linter.RuleEntry + /** + * Reports when certain comment structures are present. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-restricted-syntax.md#repos-sticky-header + */ + 'jsdoc/no-restricted-syntax'?: Linter.RuleEntry + /** + * This rule reports types being used on `@param` or `@returns`. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-types.md#repos-sticky-header + */ + 'jsdoc/no-types'?: Linter.RuleEntry + /** + * Checks that types in jsdoc comments are defined. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/no-undefined-types.md#repos-sticky-header + */ + 'jsdoc/no-undefined-types'?: Linter.RuleEntry + /** + * Requires that each JSDoc line starts with an `*`. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-asterisk-prefix.md#repos-sticky-header + */ + 'jsdoc/require-asterisk-prefix'?: Linter.RuleEntry + /** + * Requires that all functions have a description. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-description.md#repos-sticky-header + */ + 'jsdoc/require-description'?: Linter.RuleEntry + /** + * Requires that block description, explicit `@description`, and `@param`/`@returns` tag descriptions are written in complete sentences. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-description-complete-sentence.md#repos-sticky-header + */ + 'jsdoc/require-description-complete-sentence'?: Linter.RuleEntry + /** + * Requires that all functions have examples. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-example.md#repos-sticky-header + */ + 'jsdoc/require-example'?: Linter.RuleEntry + /** + * Checks that all files have one `@file`, `@fileoverview`, or `@overview` tag at the beginning of the file. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-file-overview.md#repos-sticky-header + */ + 'jsdoc/require-file-overview'?: Linter.RuleEntry + /** + * Requires a hyphen before the `@param` description. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-hyphen-before-param-description.md#repos-sticky-header + */ + 'jsdoc/require-hyphen-before-param-description'?: Linter.RuleEntry + /** + * Require JSDoc comments + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-jsdoc.md#repos-sticky-header + */ + 'jsdoc/require-jsdoc'?: Linter.RuleEntry + /** + * Requires that all function parameters are documented. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-param.md#repos-sticky-header + */ + 'jsdoc/require-param'?: Linter.RuleEntry + /** + * Requires that each `@param` tag has a `description` value. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-param-description.md#repos-sticky-header + */ + 'jsdoc/require-param-description'?: Linter.RuleEntry + /** + * Requires that all function parameters have names. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-param-name.md#repos-sticky-header + */ + 'jsdoc/require-param-name'?: Linter.RuleEntry + /** + * Requires that each `@param` tag has a `type` value. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-param-type.md#repos-sticky-header + */ + 'jsdoc/require-param-type'?: Linter.RuleEntry + /** + * Requires that all `@typedef` and `@namespace` tags have `@property` when their type is a plain `object`, `Object`, or `PlainObject`. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-property.md#repos-sticky-header + */ + 'jsdoc/require-property'?: Linter.RuleEntry<[]> + /** + * Requires that each `@property` tag has a `description` value. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-property-description.md#repos-sticky-header + */ + 'jsdoc/require-property-description'?: Linter.RuleEntry<[]> + /** + * Requires that all function `@property` tags have names. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-property-name.md#repos-sticky-header + */ + 'jsdoc/require-property-name'?: Linter.RuleEntry<[]> + /** + * Requires that each `@property` tag has a `type` value. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-property-type.md#repos-sticky-header + */ + 'jsdoc/require-property-type'?: Linter.RuleEntry<[]> + /** + * Requires that returns are documented. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns.md#repos-sticky-header + */ + 'jsdoc/require-returns'?: Linter.RuleEntry + /** + * Requires a return statement in function body if a `@returns` tag is specified in jsdoc comment. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns-check.md#repos-sticky-header + */ + 'jsdoc/require-returns-check'?: Linter.RuleEntry + /** + * Requires that the `@returns` tag has a `description` value. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns-description.md#repos-sticky-header + */ + 'jsdoc/require-returns-description'?: Linter.RuleEntry + /** + * Requires that `@returns` tag has `type` value. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-returns-type.md#repos-sticky-header + */ + 'jsdoc/require-returns-type'?: Linter.RuleEntry + /** + * Requires template tags for each generic type parameter + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-template.md#repos-sticky-header + */ + 'jsdoc/require-template'?: Linter.RuleEntry + /** + * Requires that throw statements are documented. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-throws.md#repos-sticky-header + */ + 'jsdoc/require-throws'?: Linter.RuleEntry + /** + * Requires yields are documented. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-yields.md#repos-sticky-header + */ + 'jsdoc/require-yields'?: Linter.RuleEntry + /** + * Requires a yield statement in function body if a `@yields` tag is specified in jsdoc comment. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-yields-check.md#repos-sticky-header + */ + 'jsdoc/require-yields-check'?: Linter.RuleEntry + /** + * Sorts tags by a specified sequence according to tag name. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/sort-tags.md#repos-sticky-header + */ + 'jsdoc/sort-tags'?: Linter.RuleEntry + /** + * Enforces lines (or no lines) between tags. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/tag-lines.md#repos-sticky-header + */ + 'jsdoc/tag-lines'?: Linter.RuleEntry + /** + * Auto-escape certain characters that are input within block and tag descriptions. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/text-escaping.md#repos-sticky-header + */ + 'jsdoc/text-escaping'?: Linter.RuleEntry + /** + * Requires all types to be valid JSDoc or Closure compiler types without syntax errors. + * @see https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/valid-types.md#repos-sticky-header + */ + 'jsdoc/valid-types'?: Linter.RuleEntry /** * Enforce emojis are wrapped in `` and provide screen reader access. * @see https://github.com/jsx-eslint/eslint-plugin-jsx-a11y/tree/HEAD/docs/rules/accessible-emoji.md @@ -8085,6 +8370,466 @@ type JestValidTitle = []|[{ [k: string]: (string | [string]|[string, string]) | undefined }) }] +// ----- jsdoc/check-examples ----- +type JsdocCheckExamples = []|[{ + allowInlineConfig?: boolean + baseConfig?: { + [k: string]: unknown | undefined + } + captionRequired?: boolean + checkDefaults?: boolean + checkEslintrc?: boolean + checkParams?: boolean + checkProperties?: boolean + configFile?: string + exampleCodeRegex?: string + matchingFileName?: string + matchingFileNameDefaults?: string + matchingFileNameParams?: string + matchingFileNameProperties?: string + noDefaultExampleRules?: boolean + paddedIndent?: number + rejectExampleCodeRegex?: string + reportUnusedDisableDirectives?: boolean +}] +// ----- jsdoc/check-indentation ----- +type JsdocCheckIndentation = []|[{ + excludeTags?: string[] +}] +// ----- jsdoc/check-line-alignment ----- +type JsdocCheckLineAlignment = []|[("always" | "never" | "any")]|[("always" | "never" | "any"), { + customSpacings?: { + postDelimiter?: number + postHyphen?: number + postName?: number + postTag?: number + postType?: number + } + preserveMainDescriptionPostDelimiter?: boolean + tags?: string[] + wrapIndent?: string + disableWrapIndent?: boolean +}] +// ----- jsdoc/check-param-names ----- +type JsdocCheckParamNames = []|[{ + allowExtraTrailingParamDocs?: boolean + checkDestructured?: boolean + checkRestProperty?: boolean + checkTypesPattern?: string + disableExtraPropertyReporting?: boolean + disableMissingParamChecks?: boolean + enableFixer?: boolean + useDefaultObjectProperties?: boolean +}] +// ----- jsdoc/check-property-names ----- +type JsdocCheckPropertyNames = []|[{ + enableFixer?: boolean +}] +// ----- jsdoc/check-tag-names ----- +type JsdocCheckTagNames = []|[{ + definedTags?: string[] + enableFixer?: boolean + jsxTags?: boolean + typed?: boolean +}] +// ----- jsdoc/check-types ----- +type JsdocCheckTypes = []|[{ + exemptTagContexts?: { + tag?: string + types?: (boolean | string[]) + }[] + noDefaults?: boolean + unifyParentAndChildTypeChecks?: boolean +}] +// ----- jsdoc/check-values ----- +type JsdocCheckValues = []|[{ + allowedAuthors?: string[] + allowedLicenses?: (string[] | boolean) + licensePattern?: string + numericOnlyVariation?: boolean +}] +// ----- jsdoc/convert-to-jsdoc-comments ----- +type JsdocConvertToJsdocComments = []|[{ + allowedPrefixes?: string[] + contexts?: (string | { + context?: string + inlineCommentBlock?: boolean + })[] + contextsAfter?: (string | { + context?: string + inlineCommentBlock?: boolean + })[] + contextsBeforeAndAfter?: (string | { + context?: string + inlineCommentBlock?: boolean + })[] + enableFixer?: boolean + enforceJsdocLineStyle?: ("multi" | "single") + lineOrBlockStyle?: ("block" | "line" | "both") +}] +// ----- jsdoc/empty-tags ----- +type JsdocEmptyTags = []|[{ + tags?: string[] +}] +// ----- jsdoc/implements-on-classes ----- +type JsdocImplementsOnClasses = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] +}] +// ----- jsdoc/informative-docs ----- +type JsdocInformativeDocs = []|[{ + aliases?: { + [k: string]: string[] + } + excludedTags?: string[] + uselessWords?: string[] +}] +// ----- jsdoc/lines-before-block ----- +type JsdocLinesBeforeBlock = []|[{ + checkBlockStarts?: boolean + excludedTags?: string[] + ignoreSameLine?: boolean + lines?: number +}] +// ----- jsdoc/match-description ----- +type JsdocMatchDescription = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] + mainDescription?: (string | boolean | { + match?: (string | boolean) + message?: string + }) + matchDescription?: string + message?: string + nonemptyTags?: boolean + tags?: { + [k: string]: (string | true | { + match?: (string | true) + message?: string + }) + } +}] +// ----- jsdoc/match-name ----- +type JsdocMatchName = []|[{ + match: { + allowName?: string + comment?: string + context?: string + disallowName?: string + message?: string + tags?: string[] + [k: string]: unknown | undefined + }[] +}] +// ----- jsdoc/multiline-blocks ----- +type JsdocMultilineBlocks = []|[{ + allowMultipleTags?: boolean + minimumLengthForMultiline?: number + multilineTags?: ("*" | string[]) + noFinalLineText?: boolean + noMultilineBlocks?: boolean + noSingleLineBlocks?: boolean + noZeroLineText?: boolean + singleLineTags?: string[] +}] +// ----- jsdoc/no-bad-blocks ----- +type JsdocNoBadBlocks = []|[{ + ignore?: string[] + preventAllMultiAsteriskBlocks?: boolean +}] +// ----- jsdoc/no-blank-blocks ----- +type JsdocNoBlankBlocks = []|[{ + enableFixer?: boolean +}] +// ----- jsdoc/no-defaults ----- +type JsdocNoDefaults = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] + noOptionalParamNames?: boolean +}] +// ----- jsdoc/no-missing-syntax ----- +type JsdocNoMissingSyntax = []|[{ + contexts?: (string | { + comment?: string + context?: string + message?: string + minimum?: number + })[] +}] +// ----- jsdoc/no-multi-asterisks ----- +type JsdocNoMultiAsterisks = []|[{ + allowWhitespace?: boolean + preventAtEnd?: boolean + preventAtMiddleLines?: boolean +}] +// ----- jsdoc/no-restricted-syntax ----- +type JsdocNoRestrictedSyntax = []|[{ + contexts: (string | { + comment?: string + context?: string + message?: string + })[] +}] +// ----- jsdoc/no-types ----- +type JsdocNoTypes = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] +}] +// ----- jsdoc/no-undefined-types ----- +type JsdocNoUndefinedTypes = []|[{ + definedTypes?: string[] + disableReporting?: boolean + markVariablesAsUsed?: boolean +}] +// ----- jsdoc/require-asterisk-prefix ----- +type JsdocRequireAsteriskPrefix = []|[("always" | "never" | "any")]|[("always" | "never" | "any"), { + tags?: { + always?: string[] + any?: string[] + never?: string[] + [k: string]: unknown | undefined + } +}] +// ----- jsdoc/require-description ----- +type JsdocRequireDescription = []|[{ + checkConstructors?: boolean + checkGetters?: boolean + checkSetters?: boolean + contexts?: (string | { + comment?: string + context?: string + })[] + descriptionStyle?: ("body" | "tag" | "any") + exemptedBy?: string[] +}] +// ----- jsdoc/require-description-complete-sentence ----- +type JsdocRequireDescriptionCompleteSentence = []|[{ + abbreviations?: string[] + newlineBeforeCapsAssumesBadSentenceEnd?: boolean + tags?: string[] +}] +// ----- jsdoc/require-example ----- +type JsdocRequireExample = []|[{ + checkConstructors?: boolean + checkGetters?: boolean + checkSetters?: boolean + contexts?: (string | { + comment?: string + context?: string + })[] + enableFixer?: boolean + exemptedBy?: string[] + exemptNoArguments?: boolean +}] +// ----- jsdoc/require-file-overview ----- +type JsdocRequireFileOverview = []|[{ + tags?: { + [k: string]: { + initialCommentsOnly?: boolean + mustExist?: boolean + preventDuplicates?: boolean + } + } +}] +// ----- jsdoc/require-hyphen-before-param-description ----- +type JsdocRequireHyphenBeforeParamDescription = []|[("always" | "never")]|[("always" | "never"), { + tags?: ({ + [k: string]: ("always" | "never") + } | "any") +}] +// ----- jsdoc/require-jsdoc ----- +type JsdocRequireJsdoc = []|[{ + checkConstructors?: boolean + checkGetters?: (boolean | "no-setter") + checkSetters?: (boolean | "no-getter") + contexts?: (string | { + context?: string + inlineCommentBlock?: boolean + minLineCount?: number + })[] + enableFixer?: boolean + exemptEmptyConstructors?: boolean + exemptEmptyFunctions?: boolean + fixerMessage?: string + minLineCount?: number + publicOnly?: (boolean | { + ancestorsOnly?: boolean + cjs?: boolean + esm?: boolean + window?: boolean + }) + require?: { + ArrowFunctionExpression?: boolean + ClassDeclaration?: boolean + ClassExpression?: boolean + FunctionDeclaration?: boolean + FunctionExpression?: boolean + MethodDefinition?: boolean + } +}] +// ----- jsdoc/require-param ----- +type JsdocRequireParam = []|[{ + autoIncrementBase?: number + checkConstructors?: boolean + checkDestructured?: boolean + checkDestructuredRoots?: boolean + checkGetters?: boolean + checkRestProperty?: boolean + checkSetters?: boolean + checkTypesPattern?: string + contexts?: (string | { + comment?: string + context?: string + })[] + enableFixer?: boolean + enableRestElementFixer?: boolean + enableRootFixer?: boolean + exemptedBy?: string[] + ignoreWhenAllParamsMissing?: boolean + unnamedRootBase?: string[] + useDefaultObjectProperties?: boolean +}] +// ----- jsdoc/require-param-description ----- +type JsdocRequireParamDescription = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] + defaultDestructuredRootDescription?: string + setDefaultDestructuredRootDescription?: boolean +}] +// ----- jsdoc/require-param-name ----- +type JsdocRequireParamName = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] +}] +// ----- jsdoc/require-param-type ----- +type JsdocRequireParamType = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] + defaultDestructuredRootType?: string + setDefaultDestructuredRootType?: boolean +}] +// ----- jsdoc/require-returns ----- +type JsdocRequireReturns = []|[{ + checkConstructors?: boolean + checkGetters?: boolean + contexts?: (string | { + comment?: string + context?: string + forceRequireReturn?: boolean + })[] + enableFixer?: boolean + exemptedBy?: string[] + forceRequireReturn?: boolean + forceReturnsWithAsync?: boolean + publicOnly?: (boolean | { + ancestorsOnly?: boolean + cjs?: boolean + esm?: boolean + window?: boolean + }) +}] +// ----- jsdoc/require-returns-check ----- +type JsdocRequireReturnsCheck = []|[{ + exemptAsync?: boolean + exemptGenerators?: boolean + reportMissingReturnForUndefinedTypes?: boolean +}] +// ----- jsdoc/require-returns-description ----- +type JsdocRequireReturnsDescription = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] +}] +// ----- jsdoc/require-returns-type ----- +type JsdocRequireReturnsType = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] +}] +// ----- jsdoc/require-template ----- +type JsdocRequireTemplate = []|[{ + requireSeparateTemplates?: boolean +}] +// ----- jsdoc/require-throws ----- +type JsdocRequireThrows = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] + exemptedBy?: string[] +}] +// ----- jsdoc/require-yields ----- +type JsdocRequireYields = []|[{ + contexts?: (string | { + comment?: string + context?: string + })[] + exemptedBy?: string[] + forceRequireNext?: boolean + forceRequireYields?: boolean + next?: boolean + nextWithGeneratorTag?: boolean + withGeneratorTag?: boolean +}] +// ----- jsdoc/require-yields-check ----- +type JsdocRequireYieldsCheck = []|[{ + checkGeneratorsOnly?: boolean + contexts?: (string | { + comment?: string + context?: string + })[] + exemptedBy?: string[] + next?: boolean +}] +// ----- jsdoc/sort-tags ----- +type JsdocSortTags = []|[{ + alphabetizeExtras?: boolean + linesBetween?: number + reportIntraTagGroupSpacing?: boolean + reportTagGroupSpacing?: boolean + tagSequence?: { + tags?: string[] + [k: string]: unknown | undefined + }[] +}] +// ----- jsdoc/tag-lines ----- +type JsdocTagLines = []|[("always" | "any" | "never")]|[("always" | "any" | "never"), { + applyToEndTag?: boolean + count?: number + endLines?: (number | null) + startLines?: (number | null) + tags?: { + [k: string]: { + count?: number + lines?: ("always" | "never" | "any") + } + } +}] +// ----- jsdoc/text-escaping ----- +type JsdocTextEscaping = []|[{ + escapeHTML?: boolean + escapeMarkdown?: boolean +}] +// ----- jsdoc/valid-types ----- +type JsdocValidTypes = []|[{ + allowEmptyNamepaths?: boolean +}] // ----- jsx-a11y/accessible-emoji ----- type JsxA11YAccessibleEmoji = []|[{ [k: string]: unknown | undefined diff --git a/src/rules/__snapshots__/jsdoc.spec.ts.snap b/src/rules/__snapshots__/jsdoc.spec.ts.snap new file mode 100644 index 0000000..f708fc7 --- /dev/null +++ b/src/rules/__snapshots__/jsdoc.spec.ts.snap @@ -0,0 +1,74 @@ +// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html + +exports[`should create jsdoc rules 1`] = ` +{ + "jsdoc/check-access": "error", + "jsdoc/check-alignment": "error", + "jsdoc/check-examples": "off", + "jsdoc/check-indentation": "off", + "jsdoc/check-line-alignment": "off", + "jsdoc/check-param-names": "error", + "jsdoc/check-property-names": "error", + "jsdoc/check-syntax": "off", + "jsdoc/check-tag-names": [ + "error", + { + "typed": true, + }, + ], + "jsdoc/check-template-names": "off", + "jsdoc/check-types": "error", + "jsdoc/check-values": "error", + "jsdoc/convert-to-jsdoc-comments": "off", + "jsdoc/empty-tags": "error", + "jsdoc/implements-on-classes": "error", + "jsdoc/imports-as-dependencies": "off", + "jsdoc/informative-docs": "off", + "jsdoc/lines-before-block": "off", + "jsdoc/match-description": "off", + "jsdoc/match-name": "off", + "jsdoc/multiline-blocks": "error", + "jsdoc/no-bad-blocks": "off", + "jsdoc/no-blank-block-descriptions": "off", + "jsdoc/no-blank-blocks": "off", + "jsdoc/no-defaults": "error", + "jsdoc/no-missing-syntax": "off", + "jsdoc/no-multi-asterisks": "error", + "jsdoc/no-restricted-syntax": "off", + "jsdoc/no-types": "error", + "jsdoc/no-undefined-types": "off", + "jsdoc/require-asterisk-prefix": "off", + "jsdoc/require-description": "off", + "jsdoc/require-description-complete-sentence": "off", + "jsdoc/require-example": "off", + "jsdoc/require-file-overview": "off", + "jsdoc/require-hyphen-before-param-description": "off", + "jsdoc/require-jsdoc": "off", + "jsdoc/require-param": "off", + "jsdoc/require-param-description": "error", + "jsdoc/require-param-name": "error", + "jsdoc/require-param-type": "off", + "jsdoc/require-property": "error", + "jsdoc/require-property-description": "error", + "jsdoc/require-property-name": "error", + "jsdoc/require-property-type": "off", + "jsdoc/require-returns": "off", + "jsdoc/require-returns-check": "error", + "jsdoc/require-returns-description": "error", + "jsdoc/require-returns-type": "off", + "jsdoc/require-template": "off", + "jsdoc/require-throws": "off", + "jsdoc/require-yields": "error", + "jsdoc/require-yields-check": "error", + "jsdoc/sort-tags": "off", + "jsdoc/tag-lines": [ + "error", + "always", + { + "applyToEndTag": false, + }, + ], + "jsdoc/text-escaping": "off", + "jsdoc/valid-types": "error", +} +`; diff --git a/src/rules/jsdoc.spec.ts b/src/rules/jsdoc.spec.ts new file mode 100644 index 0000000..af5841c --- /dev/null +++ b/src/rules/jsdoc.spec.ts @@ -0,0 +1,5 @@ +import { jsdocRules } from "./jsdoc"; + +test("should create jsdoc rules", () => { + expect(jsdocRules()).toMatchSnapshot(); +}); diff --git a/src/rules/jsdoc.ts b/src/rules/jsdoc.ts new file mode 100644 index 0000000..c7d3d56 --- /dev/null +++ b/src/rules/jsdoc.ts @@ -0,0 +1,19 @@ +import jsdocPlugin from "eslint-plugin-jsdoc"; + +import type { Rules } from "../types"; + +export const jsdocRules = () => { + return { + ...jsdocPlugin.configs["flat/recommended-typescript-error"].rules, + "jsdoc/require-jsdoc": "off", + "jsdoc/require-param": "off", + "jsdoc/require-returns": "off", + "jsdoc/tag-lines": [ + "error", + "always", + { + applyToEndTag: false, + }, + ], + } satisfies Rules; +}; diff --git a/src/types.ts b/src/types.ts index d634018..1f8ced4 100644 --- a/src/types.ts +++ b/src/types.ts @@ -53,7 +53,6 @@ export type TypedConfigItem = Omit< > & { /** * An object containing a name-value mapping of plugin names to plugin objects. When `files` is specified, these plugins are only available to the matching files. - * * @see [Using plugins in your configuration](https://eslint.org/docs/latest/user-guide/configuring/configuration-files-new#using-plugins-in-your-configuration) */ // TODO: add undefined @@ -74,6 +73,7 @@ export interface Options { /** * Additional configs to either extend or overrides configurations * @deprecated please use {@link Options.configs} instead. + * * @default [] */ configs?: Linter.Config[] | TypedConfigItem[]; @@ -120,6 +120,7 @@ export interface Options { /** * Are testing rules enabled? * @default false + * * @deprecated please use {@link Options.jest}, {@link Options.vitest}, or {@link Options.testingLibrary} instead. */ testing?: boolean | TestingOptions; diff --git a/src/utils/interop-default.ts b/src/utils/interop-default.ts index 6a8f641..451de25 100644 --- a/src/utils/interop-default.ts +++ b/src/utils/interop-default.ts @@ -3,8 +3,8 @@ * Utility to safely fetch an imported `ESLint` plugin. * * Since ESLint Flat Config still isn't widely adopted, many plugins don't include types or a default import by default. Additionally, since we accept large version ranges in our peer dependencies, the structure of plugins may change at times. This function normalizes an import of a generic ESLint plugin, ensuring it is typed and accessible. - * * @param module the result of `import('eslint-plugin-name')`. + * * @returns The normalized and awaited default export. */ export const interopDefault = async (