markdownlint 0.37.0 → 0.37.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,14 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.37.2
4
+
5
+ - Add subpath imports for overriding default bundler behavior
6
+ - Improve MD032
7
+
8
+ ## 0.37.1
9
+
10
+ - Add support for "browser" condition (as used by webpack)
11
+
3
12
  ## 0.37.0
4
13
 
5
14
  - Convert module to ECMAScript (breaking change)
package/helpers/README.md CHANGED
@@ -22,8 +22,8 @@ be useful to custom rule authors and may avoid duplicating code.
22
22
  *None* - The entire body of code is tested to 100% coverage by the core
23
23
  `markdownlint` project, so there are no additional tests here.
24
24
 
25
- [custom-rules]: https://github.com/DavidAnson/markdownlint/blob/v0.37.0/doc/CustomRules.md
25
+ [custom-rules]: https://github.com/DavidAnson/markdownlint/blob/v0.37.2/doc/CustomRules.md
26
26
  [jsdoc]: https://en.m.wikipedia.org/wiki/JSDoc
27
27
  [markdown]: https://en.wikipedia.org/wiki/Markdown
28
28
  [markdownlint]: https://github.com/DavidAnson/markdownlint
29
- [rules]: https://github.com/DavidAnson/markdownlint/blob/v0.37.0/doc/Rules.md
29
+ [rules]: https://github.com/DavidAnson/markdownlint/blob/v0.37.2/doc/Rules.md
@@ -10,11 +10,11 @@ module.exports.newLineRe = newLineRe;
10
10
  module.exports.nextLinesRe = nextLinesRe;
11
11
 
12
12
  // @ts-expect-error https://github.com/microsoft/TypeScript/issues/52529
13
- /** @typedef {import("markdownlint").RuleOnError} RuleOnError */
13
+ /** @typedef {import("../lib/exports.mjs").RuleOnError} RuleOnError */
14
14
  // @ts-expect-error https://github.com/microsoft/TypeScript/issues/52529
15
- /** @typedef {import("markdownlint").RuleOnErrorFixInfo} RuleOnErrorFixInfo */
15
+ /** @typedef {import("../lib/exports.mjs").RuleOnErrorFixInfo} RuleOnErrorFixInfo */
16
16
  // @ts-expect-error https://github.com/microsoft/TypeScript/issues/52529
17
- /** @typedef {import("markdownlint").MicromarkToken} MicromarkToken */
17
+ /** @typedef {import("../lib/exports.mjs").MicromarkToken} MicromarkToken */
18
18
  // eslint-disable-next-line jsdoc/valid-types
19
19
  /** @typedef {import("micromark-extension-gfm-footnote", { with: { "resolution-mode": "import" } })} */
20
20
  // eslint-disable-next-line jsdoc/valid-types
@@ -7,7 +7,7 @@ const { flatTokensSymbol, htmlFlowSymbol } = require("./shared.cjs");
7
7
  // eslint-disable-next-line jsdoc/valid-types
8
8
  /** @typedef {import("micromark-util-types", { with: { "resolution-mode": "import" } }).TokenType} TokenType */
9
9
  // @ts-expect-error https://github.com/microsoft/TypeScript/issues/52529
10
- /** @typedef {import("markdownlint").MicromarkToken} Token */
10
+ /** @typedef {import("../lib/exports.mjs").MicromarkToken} Token */
11
11
 
12
12
  /**
13
13
  * Determines if a Micromark token is within an htmlFlow type.
@@ -78,12 +78,11 @@ function addRangeToSet(set, start, end) {
78
78
  * Filter a list of Micromark tokens by predicate.
79
79
  *
80
80
  * @param {Token[]} tokens Micromark tokens.
81
- * @param {AllowedPredicate} [allowed] Allowed token predicate.
81
+ * @param {AllowedPredicate} allowed Allowed token predicate.
82
82
  * @param {TransformPredicate} [transformChildren] Transform predicate.
83
83
  * @returns {Token[]} Filtered tokens.
84
84
  */
85
85
  function filterByPredicate(tokens, allowed, transformChildren) {
86
- allowed = allowed || (() => true);
87
86
  const result = [];
88
87
  const queue = [
89
88
  {
@@ -278,7 +277,11 @@ const nonContentTokens = new Set([
278
277
  "lineEnding",
279
278
  "lineEndingBlank",
280
279
  "linePrefix",
281
- "listItemIndent"
280
+ "listItemIndent",
281
+ "undefinedReference",
282
+ "undefinedReferenceCollapsed",
283
+ "undefinedReferenceFull",
284
+ "undefinedReferenceShortcut"
282
285
  ]);
283
286
 
284
287
  module.exports = {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "markdownlint-rule-helpers",
3
- "version": "0.27.0",
3
+ "version": "0.28.0",
4
4
  "description": "A collection of markdownlint helper functions for custom rules",
5
5
  "main": "./helpers.cjs",
6
6
  "exports": {