Skip to content

expiring-todo-comments: should not flag eslint disable comments#2828

Merged
sindresorhus merged 15 commits into
sindresorhus:mainfrom
Vladyslav-Soldatenko:feat/expiring-todo-eslint-directives
Feb 7, 2026
Merged

expiring-todo-comments: should not flag eslint disable comments#2828
sindresorhus merged 15 commits into
sindresorhus:mainfrom
Vladyslav-Soldatenko:feat/expiring-todo-eslint-directives

Conversation

@Vladyslav-Soldatenko
Copy link
Copy Markdown
Contributor

fix for #2745

@github-actions github-actions Bot changed the title expiring-todo-comments: should not flag eslint disable comments expiring-todo-comments: should not flag eslint disable comments Nov 22, 2025
Comment thread rules/expiring-todo-comments.js Outdated
@Vladyslav-Soldatenko Vladyslav-Soldatenko force-pushed the feat/expiring-todo-eslint-directives branch from 7690333 to d0df7af Compare November 22, 2025 18:33
Comment thread rules/expiring-todo-comments.js Outdated
Comment thread rules/utils/parse-directive-comment.js Outdated
Comment thread rules/utils/parse-directive.js Outdated
Copy link
Copy Markdown
Collaborator

@fisker fisker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@fisker fisker marked this pull request as draft November 23, 2025 15:03
@fisker
Copy link
Copy Markdown
Collaborator

fisker commented Nov 23, 2025

@Vladyslav-Soldatenko Turns out there is an sourceCode.getDisableDirectives() we can use directly!

@fisker fisker marked this pull request as ready for review November 23, 2025 15:55
context.on('Program', function * () {
for (const directive of getEslintDisableDirectives(context)) {
if (directive.value) {
continue;
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a bug, using return instead of continue, introduced by me in #2571

@Vladyslav-Soldatenko
Copy link
Copy Markdown
Contributor Author

Vladyslav-Soldatenko commented Dec 2, 2025

Hi, @fisker. Are there any plans when the fix will be merged? Thanks

@sindresorhus sindresorhus merged commit 3568daf into sindresorhus:main Feb 7, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants