mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2026-04-26 01:36:03 +03:00
[GH-ISSUE #306] Add ability ignore specific rule with settings.json #2110
Labels
No labels
bug
enhancement
enhancement
enhancement
fixed in next
fixed in next
fixed in next
new rule
new rule
new rule
pull-request
question
refactoring
refactoring
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/markdownlint#2110
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @marsfan on GitHub (Jul 21, 2020).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/306
Not sure if I have missed this in the manual, or in another issue, but it would be really nice if I could specify which issues to ignore specific rules on a global in Visual Studio Code's own
settings.jsonfile, so that I do not have to have a separate configuration file just for the extension.@nschonni commented on GitHub (Jul 21, 2020):
Think you're looking for this project https://github.com/DavidAnson/vscode-markdownlint
@marsfan commented on GitHub (Jul 21, 2020):
Whoops. Clicked the wrong link I guess. Thanks
@marsfan commented on GitHub (Jul 21, 2020):
Also, I want to add,for anyone who stumbles across this issue. It is already possible to ignore specific rules with settings.json.
Here is an example of how to disable the rules MD022 and MD032:
@dkadrios commented on GitHub (Oct 6, 2020):
Am I crazy, or is it impossible to disable MD029 ?
MD029 deals with the ordering of lists. I have a situation where there is a code block between two list items. Normally that wouldn't produce the desired output, however I use 'sane lists' and it looks great https://python-markdown.github.io/extensions/sane_lists/
MD029 flags items three and four as warnings and I've not been able to disable it in eslint. I've already disabled MD033 and MD041 (reasons) so I know the setup works, just not for MD029
EDIT:
I was able to get around this by wrapping items three and four with:
This works on a case-by-case basis -- it just doesn't work in globally in .eslintrc
@DavidAnson commented on GitHub (Oct 7, 2020):
MD029 is disable-able per example below.
But I'm not sure how you would do so from an ESLint-specific config file?
https://dlaa.me/markdownlint/#%25m%23%20Disable%20MD029%0A%0A1.%20Item%0A2.%20Item%0A%0AText%0A%0A3.%20Item%0A4.%20Item%0A%0AText%20%3C!--%20markdownlint-disable%20MD029%20--%3E%0A%0A5.%20Item%0A6.%20Item%0A
@TRezendes commented on GitHub (Jun 5, 2023):
Thank you @marsfan. This is the only place I could find this method explained simply and clearly.
@DavidAnson commented on GitHub (Jun 5, 2023):
Just in case there are more people coming here to look for documentation about the VS Code extension, there is a description and an example of this in the README for that project: https://github.com/DavidAnson/vscode-markdownlint#markdownlintconfig
@TRezendes commented on GitHub (Jun 6, 2023):
Perhaps it's just my lack of familiarity with the ins and outs of VSCode, but I read the "Configure" section of the documentation several times and did not understand that there was a method for disabling rules globally. I see it now, but that section still reads to me as though it is merely explaining that some rules are disabled by default, not how or where to disable other rules.