Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix no-disable regression for some rules #6018

Merged
merged 1 commit into from Apr 17, 2022
Merged

Fix no-disable regression for some rules #6018

merged 1 commit into from Apr 17, 2022

Conversation

ota-meshi
Copy link
Member

Which issue, if any, is this issue related to?

Closes #6015

Is there anything in the PR that needs further explanation?

This PR is modified so that stylelint-disable is enabled when the start line of the report matches.

@ota-meshi
Copy link
Member Author

For example, the selector-class-pattern rule currently reports a range of rule node. So the report range in the following example is from line 1 to line 3.

.ProseMirror { /* stylelint-disable-line selector-class-pattern */
  ...
}

The stylelint-disable-line cannot suppress range reporting, so it has no effect in the above example.

After this PR change, the suppression comment works because it only refers to the start line of the report (line 1 in the example).

@ota-meshi
Copy link
Member Author

Copy link
Member

@ybiquitous ybiquitous left a comment

Choose a reason for hiding this comment

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

@ota-meshi Thank you so much! LGTM 👍🏼

Copy link
Member

@jeddy3 jeddy3 left a comment

Choose a reason for hiding this comment

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

@ota-meshi Many thanks for the quick fix!

I'll put out a release now.

@jeddy3 jeddy3 merged commit ba35f87 into main Apr 17, 2022
@jeddy3 jeddy3 deleted the fix-disable branch April 17, 2022 13:57
@jeddy3
Copy link
Member

jeddy3 commented Apr 17, 2022

  • Fixed: a regression for /* stylelint-disable */ comments (#6018).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Fix no-disable regression for some rules
3 participants