eslint-plugin-jsdoc 64.3.3 → 64.3.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/iterateJsdoc.js +7 -0
package/package.json
CHANGED
package/src/iterateJsdoc.js
CHANGED
|
@@ -2338,6 +2338,13 @@ const iterateAllJsdocs = (iterator, ruleConfig, contexts, additiveCommentContext
|
|
|
2338
2338
|
// @ts-expect-error ESLint < 10
|
|
2339
2339
|
sourceCode = context.getSourceCode(),
|
|
2340
2340
|
} = context;
|
|
2341
|
+
|
|
2342
|
+
// Custom languages provide their own `SourceCode` implementations.
|
|
2343
|
+
// JSDoc traversal requires the JavaScript token API.
|
|
2344
|
+
if (typeof sourceCode.getTokenBefore !== 'function') {
|
|
2345
|
+
return {};
|
|
2346
|
+
}
|
|
2347
|
+
|
|
2341
2348
|
settings = getSettings(context);
|
|
2342
2349
|
if (!settings) {
|
|
2343
2350
|
return {};
|