Commit graph

470 commits

Author SHA1 Message Date
David Anson
c699b8e22b Allow a custom rule's onError implementation to override that rule's information URL for each error. 2023-07-11 21:45:00 -07:00
David Anson
7a794192ca Add support for named heading fragments as supported by some platforms (fixes #830). 2023-07-08 22:14:00 -07:00
David Anson
c06506c317 Reimplement MD026/no-trailing-punctuation using micromark tokens, ignore trailing GitHub emoji codes, improve tests (fixes #457). 2023-06-24 15:47:06 -07:00
David Anson
d01180ec5a Update to version 0.29.0. 2023-06-01 20:41:10 -07:00
David Anson
b1eff75034 Update MD044/proper-names to parse into micromark htmlFlow tokens for better behavior when html_elements is false (fixes #832). 2023-05-31 20:25:56 -07:00
David Anson
8471914a1d Update MD037/no-space-in-emphasis to handle multiple embedded underscores separated by a single character (fixes #804). 2023-05-27 11:05:17 -07:00
David Anson
dc4acff067 Update MD044/proper-names to ignore the content of HTML comments when its html_elements parameter is false (fixes #832). 2023-05-26 20:58:59 -07:00
David Anson
0006636f75 Update MD049/emphasis-style and MD050/strong-style to not report intraword asterisks/underscores as violations because exchanging either alters meaning (fixes #789). 2023-05-26 04:47:14 +00:00
David Anson
7005a8a438 Reimplement MD049/emphasis-style, MD050/strong-style to use micromark parser (with smaller ranges and handling of multi-line fixes). 2023-05-26 03:50:00 +00:00
David Anson
a4a38ec9d2 Refactor MD049/emphasis-style and MD050/strong-style slightly to simplify. 2023-05-25 02:50:56 +00:00
David Anson
488813f7f7 Update MD034/no-bare-urls to re-scan documents with potential violations using proper reference definition handling to avoid false positives (fixes #787). 2023-05-23 04:01:55 +00:00
David Anson
c740cc5787 Update to version 0.28.2. 2023-04-27 20:28:52 -07:00
David Anson
fcb8190781 Update to version 0.28.1. 2023-04-05 19:30:58 -07:00
David Anson
2ab546bec0 Implement (undocumented, promise-only) extendConfig API for readConfig-like behavior when the Configuration object is already available (i.e., to implement "extends" consistently). 2023-04-03 22:59:06 -07:00
David Anson
95992f23c6 Update to version 0.28.0. 2023-03-23 22:04:35 -07:00
David Anson
5bff33d41b Reimplement MD044/proper-names using micromark tokens. 2023-03-14 21:03:07 -07:00
David Anson
e8a85c91f2 Move call to mapAliasToRuleNames higher in the stack to avoid re-computing multiple times for the same input. 2023-03-12 20:50:17 -07:00
David Anson
8057f3d37e Reimplement MD035/hr-style using micromark tokens (fixes #736). 2023-03-06 21:39:21 -08:00
David Anson
13ced64c21 Rename markdownlint-micromark Token's .tokens property to .children for consistency and clarity. 2023-02-25 15:50:58 -08:00
David Anson
962547ecc8 Reimplement MD038/no-space-in-code using micromark tokens. 2023-02-25 15:50:58 -08:00
David Anson
4b27bac79b Update all references to "params.tokens" to "params.parsers.markdownit.tokens" for clarity. 2023-02-25 15:50:57 -08:00
David Anson
b990b3ea77 Reimplement MD034/no-bare-urls using micromark tokens (fixes #707). 2023-02-25 15:50:57 -08:00
David Anson
64159fa456 Address new @ts-check warnings in markdownlint-test.js. 2023-02-25 15:50:57 -08:00
David Anson
97f99befb8 Reimplement getReferenceLinkImageData using micromark tokens. 2023-02-25 15:50:57 -08:00
David Anson
c1df46f607 Convert params.parsers.name to params.parsers.name.tokens for clarity/flexibility. 2023-02-25 15:50:56 -08:00
David Anson
c53df8b720 Fix range calculation in MD033/no-inline-html during re-parse of tabbed content. 2023-02-25 15:50:56 -08:00
David Anson
48a92d41a4 Reimplement MD033/no-inline-html using micromark tokens. 2023-02-25 15:50:56 -08:00
David Anson
08b31da0aa Move micromark.cjs helpers from lib to helpers so it can be used by code in both locations. 2023-02-25 15:50:56 -08:00
David Anson
1461ad6272 Add content parsing via micromark, publish frozen micromark tokens alongside markdown-it tokens, remove assert from micromark wrapper. 2023-02-25 15:50:56 -08:00
David Anson
fc2ed221ff Use .cjs extension for markdownlint-micromark output files for clarity. 2023-02-25 15:49:52 -08:00
David Anson
c9e8f8b8ea Convert micromark.mjs to micromark.cjs for use by synchronous APIs in markdownlint.js. 2023-02-25 15:49:52 -08:00
David Anson
bb0aa012b5 Use webpack to create a CommonJS module from micromark's ESM implementation, convert to using that. 2023-02-25 15:49:52 -08:00
David Anson
5038f6e154 Work around likely micromark bug in sliceSerialize (link to GitHub issue in code). 2023-02-25 15:49:51 -08:00
David Anson
000281e2f0 Add "// @ts-check" to top of new micromark-related modules, fix import typo. 2023-02-25 15:49:51 -08:00
David Anson
366a498150 Initial implementation of markdownlint-micromark package, micromark.mjs helpers, and tests. 2023-02-25 15:49:51 -08:00
David Anson
5a4cf179c4 Update to version 0.27.0 (closes #669). 2022-12-28 01:26:27 +00:00
David Anson
868edf889e Manually fix three new ESLint warnings from the eslint-plugin-regexp plugin (refs #657). 2022-12-19 21:51:18 -08:00
David Anson
6b01a98363 Add ESLint plugin eslint-plugin-regexp, enable recommended rules, apply all automated fixes (refs #657). 2022-12-19 21:36:24 -08:00
David Anson
8d6e0b5419 Replace helpers.urlRe with helpers.urlFe to address "innefficient regular expression" CodeQL alert, introduce function expressions as an alternative, test more inputs. 2022-12-18 15:46:19 -08:00
David Anson
ac8f495ea2 Update MD051/link-fragments to identify and fix scenarios where the link fragment has the wrong case (fixes #605). 2022-12-16 13:50:38 -08:00
David Anson
d352d4ece1 Update MD034/no-bare-urls to handle more scenarios, simplify slightly, replace blanket MD034 suppression for https://github.com/mdn/content with specific (valid) issues (refs #607). 2022-12-15 14:27:07 -08:00
David Anson
2e2937081e Rename helpers.bareUrlRe to urlRe, improve it a little, add tests 2022-12-15 13:54:54 -08:00
David Anson
5eef37751b Update MD022/blanks-around-headings to include blockquote prefix if fixing inside a blockquote (fixes #654). 2022-12-07 21:16:36 -08:00
David Anson
2146bbae5f Update MD033/no-inline-html to ignore HTML in labels for reference links/images (fixes #658). 2022-12-06 22:57:45 -08:00
David Anson
cba5e8d340 Update MD034/no-bare-urls to better handle multiple similar issues on the same line (fixes https://github.com/igorshubovych/markdownlint-cli/issues/339). 2022-12-06 22:14:40 -08:00
David Anson
f84c91d95f Update MD034/no-bare-urls to allow bare URLs inside the link text of HTML A tags (fixes 615). 2022-11-13 21:39:14 -08:00
Sébastien Règne
72439f42c6
Update MD040/fenced-code-language to add language_only parameter to reject extra data in info string. 2022-11-10 22:07:04 -08:00
David Anson
99a3f164a9 Update MD013/line-length to permit long link/image reference definitions in all modes because they can not be easily split. 2022-11-08 21:40:33 -08:00
Sébastien Règne
b73ab7fd91
Update MD040/fenced-code-language to use case-sensitive comparison for allowed languages (fixes #627). 2022-11-05 17:41:27 -07:00
David Anson
13b4340747 Update all links to rules to use md000.md instead of Rules.md#md000 (shorter, quicker, less distraction). 2022-10-30 14:58:45 -07:00