diff --git a/jsdoc.json b/jsdoc.json index 4ebaa99..0a91158 100644 --- a/jsdoc.json +++ b/jsdoc.json @@ -52,6 +52,7 @@ ], "jsdoc/check-values": "off", "jsdoc/empty-tags": "off", + "jsdoc/no-blank-blocks": "warn", "jsdoc/no-blank-block-descriptions": "warn", "jsdoc/no-defaults": "off", "jsdoc/no-multi-asterisks": [ "error", { "allowWhitespace": true } ], @@ -62,6 +63,6 @@ "jsdoc/require-property-description": "off", "jsdoc/require-property-name": "off", "jsdoc/require-returns-description": "off", - "jsdoc/tag-lines": "off" + "jsdoc/tag-lines": [ "warn", "any", { "startLines": 1 } ] } } diff --git a/package-lock.json b/package-lock.json index f9c32e7..0f61f69 100644 --- a/package-lock.json +++ b/package-lock.json @@ -14,7 +14,7 @@ "eslint-plugin-compat": "^4.2.0", "eslint-plugin-es-x": "^7.3.0", "eslint-plugin-jest": "^27.6.0", - "eslint-plugin-jsdoc": "^42.0.0", + "eslint-plugin-jsdoc": "46.9.0", "eslint-plugin-json-es": "^1.5.7", "eslint-plugin-mediawiki": "^0.5.0", "eslint-plugin-mocha": "^10.2.0", @@ -138,16 +138,16 @@ } }, "node_modules/@es-joy/jsdoccomment": { - "version": "0.37.1", - "resolved": "https://registry.npmjs.org/@es-joy/jsdoccomment/-/jsdoccomment-0.37.1.tgz", - "integrity": "sha512-5vxWJ1gEkEF0yRd0O+uK6dHJf7adrxwQSX8PuRiPfFSAbNLnY0ZJfXaZucoz14Jj2N11xn2DnlEPwWRpYpvRjg==", + "version": "0.41.0", + "resolved": "https://registry.npmjs.org/@es-joy/jsdoccomment/-/jsdoccomment-0.41.0.tgz", + "integrity": "sha512-aKUhyn1QI5Ksbqcr3fFJj16p99QdjUxXAEuFst1Z47DRyoiMwivIH9MV/ARcJOCXVjPfjITciej8ZD2O/6qUmw==", "dependencies": { - "comment-parser": "1.3.1", + "comment-parser": "1.4.1", "esquery": "^1.5.0", "jsdoc-type-pratt-parser": "~4.0.0" }, "engines": { - "node": "^14 || ^16 || ^17 || ^18 || ^19 || ^20" + "node": ">=16" } }, "node_modules/@eslint-community/eslint-utils": { @@ -697,9 +697,9 @@ } }, "node_modules/comment-parser": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/comment-parser/-/comment-parser-1.3.1.tgz", - "integrity": "sha512-B52sN2VNghyq5ofvUsqZjmk6YkihBX5vMSChmSK9v4ShjKf3Vk5Xcmgpw4o+iIgtrnM/u5FiMpz9VKb8lpBveA==", + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/comment-parser/-/comment-parser-1.4.1.tgz", + "integrity": "sha512-buhp5kePrmda3vhc5B9t7pUQXAb2Tnd0qgpkIhPhkHXxJpiPJ11H0ZEU0oBpJ2QztSbzG/ZxMj/CHsYJqRHmyg==", "engines": { "node": ">= 12.0.0" } @@ -936,21 +936,22 @@ } }, "node_modules/eslint-plugin-jsdoc": { - "version": "42.0.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-42.0.0.tgz", - "integrity": "sha512-qXYr45G8atPKowZbIOdmABukMzu9IMjAlj6j5Fe0iuUItznWSXUDiBj57ejXcbt8bkPrg83333nuz+cqGKFgcQ==", + "version": "46.9.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-46.9.0.tgz", + "integrity": "sha512-UQuEtbqLNkPf5Nr/6PPRCtr9xypXY+g8y/Q7gPa0YK7eDhh0y2lWprXRnaYbW7ACgIUvpDKy9X2bZqxtGzBG9Q==", "dependencies": { - "@es-joy/jsdoccomment": "~0.37.0", + "@es-joy/jsdoccomment": "~0.41.0", "are-docs-informative": "^0.0.2", - "comment-parser": "1.3.1", + "comment-parser": "1.4.1", "debug": "^4.3.4", "escape-string-regexp": "^4.0.0", "esquery": "^1.5.0", - "semver": "^7.3.8", + "is-builtin-module": "^3.2.1", + "semver": "^7.5.4", "spdx-expression-parse": "^3.0.1" }, "engines": { - "node": "^14 || ^16 || ^17 || ^18 || ^19" + "node": ">=16" }, "peerDependencies": { "eslint": "^7.0.0 || ^8.0.0" @@ -2770,11 +2771,11 @@ } }, "@es-joy/jsdoccomment": { - "version": "0.37.1", - "resolved": "https://registry.npmjs.org/@es-joy/jsdoccomment/-/jsdoccomment-0.37.1.tgz", - "integrity": "sha512-5vxWJ1gEkEF0yRd0O+uK6dHJf7adrxwQSX8PuRiPfFSAbNLnY0ZJfXaZucoz14Jj2N11xn2DnlEPwWRpYpvRjg==", + "version": "0.41.0", + "resolved": "https://registry.npmjs.org/@es-joy/jsdoccomment/-/jsdoccomment-0.41.0.tgz", + "integrity": "sha512-aKUhyn1QI5Ksbqcr3fFJj16p99QdjUxXAEuFst1Z47DRyoiMwivIH9MV/ARcJOCXVjPfjITciej8ZD2O/6qUmw==", "requires": { - "comment-parser": "1.3.1", + "comment-parser": "1.4.1", "esquery": "^1.5.0", "jsdoc-type-pratt-parser": "~4.0.0" } @@ -3136,9 +3137,9 @@ "dev": true }, "comment-parser": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/comment-parser/-/comment-parser-1.3.1.tgz", - "integrity": "sha512-B52sN2VNghyq5ofvUsqZjmk6YkihBX5vMSChmSK9v4ShjKf3Vk5Xcmgpw4o+iIgtrnM/u5FiMpz9VKb8lpBveA==" + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/comment-parser/-/comment-parser-1.4.1.tgz", + "integrity": "sha512-buhp5kePrmda3vhc5B9t7pUQXAb2Tnd0qgpkIhPhkHXxJpiPJ11H0ZEU0oBpJ2QztSbzG/ZxMj/CHsYJqRHmyg==" }, "concat-map": { "version": "0.0.1", @@ -3302,17 +3303,18 @@ } }, "eslint-plugin-jsdoc": { - "version": "42.0.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-42.0.0.tgz", - "integrity": "sha512-qXYr45G8atPKowZbIOdmABukMzu9IMjAlj6j5Fe0iuUItznWSXUDiBj57ejXcbt8bkPrg83333nuz+cqGKFgcQ==", + "version": "46.9.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-jsdoc/-/eslint-plugin-jsdoc-46.9.0.tgz", + "integrity": "sha512-UQuEtbqLNkPf5Nr/6PPRCtr9xypXY+g8y/Q7gPa0YK7eDhh0y2lWprXRnaYbW7ACgIUvpDKy9X2bZqxtGzBG9Q==", "requires": { - "@es-joy/jsdoccomment": "~0.37.0", + "@es-joy/jsdoccomment": "~0.41.0", "are-docs-informative": "^0.0.2", - "comment-parser": "1.3.1", + "comment-parser": "1.4.1", "debug": "^4.3.4", "escape-string-regexp": "^4.0.0", "esquery": "^1.5.0", - "semver": "^7.3.8", + "is-builtin-module": "^3.2.1", + "semver": "^7.5.4", "spdx-expression-parse": "^3.0.1" } }, diff --git a/package.json b/package.json index 3014f13..2417fe2 100644 --- a/package.json +++ b/package.json @@ -70,7 +70,7 @@ "eslint-plugin-compat": "^4.2.0", "eslint-plugin-es-x": "^7.3.0", "eslint-plugin-jest": "^27.6.0", - "eslint-plugin-jsdoc": "^42.0.0", + "eslint-plugin-jsdoc": "46.9.0", "eslint-plugin-json-es": "^1.5.7", "eslint-plugin-mediawiki": "^0.5.0", "eslint-plugin-mocha": "^10.2.0", diff --git a/test/fixtures/jsdoc/invalid.js b/test/fixtures/jsdoc/invalid.js index 6ba3163..87d905b 100644 --- a/test/fixtures/jsdoc/invalid.js +++ b/test/fixtures/jsdoc/invalid.js @@ -21,6 +21,12 @@ let APP; /* eslint-enable jsdoc/check-property-names, jsdoc/no-blank-block-descriptions */ + /* eslint-disable jsdoc/no-blank-blocks */ + /** + * + */ + /* eslint-enable jsdoc/no-blank-blocks */ + /* eslint-disable jsdoc/require-property-type */ /** * @property Bar @@ -91,6 +97,18 @@ }; /* eslint-enable jsdoc/require-returns-type */ + /* eslint-disable jsdoc/tag-lines */ + /** + * Description + * @param {Object} bar + * @param {string} bar.module `module` property threw an error in eslint-plugin-jsdoc<37.5.0 + * @return {number} + */ + APP.method = function ( bar ) { + return bar; + }; + /* eslint-enable jsdoc/tag-lines */ + // eslint-disable-next-line jsdoc/check-access /** * @public diff --git a/test/fixtures/jsdoc/valid.js b/test/fixtures/jsdoc/valid.js index decbcb4..d496e35 100644 --- a/test/fixtures/jsdoc/valid.js +++ b/test/fixtures/jsdoc/valid.js @@ -13,6 +13,7 @@ // Off: jsdoc/require-file-overview // Off: jsdoc/require-hyphen-before-param-description // Off: jsdoc/require-property +/* global Foo, APP */ ( function () { // Off: jsdoc/require-property-description // Off: jsdoc/require-property-name @@ -22,7 +23,6 @@ let APP; // Valid: settings.jsdoc.tagNamePreference - // Off: jsdoc/tag-lines // Off: jsdoc/sort-tags /** * Non-default aliases: