@alexlit/lint-kit 112.3.2 → 112.3.4

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.
Files changed (266) hide show
  1. package/package.json +1 -1
  2. package/scripts/release.sh +4 -2
  3. package/packages/config-markdownlint/node_modules/entities/LICENSE +0 -11
  4. package/packages/config-markdownlint/node_modules/entities/lib/decode.d.ts +0 -211
  5. package/packages/config-markdownlint/node_modules/entities/lib/decode.d.ts.map +0 -1
  6. package/packages/config-markdownlint/node_modules/entities/lib/decode.js +0 -536
  7. package/packages/config-markdownlint/node_modules/entities/lib/decode.js.map +0 -1
  8. package/packages/config-markdownlint/node_modules/entities/lib/decode_codepoint.d.ts +0 -19
  9. package/packages/config-markdownlint/node_modules/entities/lib/decode_codepoint.d.ts.map +0 -1
  10. package/packages/config-markdownlint/node_modules/entities/lib/decode_codepoint.js +0 -76
  11. package/packages/config-markdownlint/node_modules/entities/lib/decode_codepoint.js.map +0 -1
  12. package/packages/config-markdownlint/node_modules/entities/lib/encode.d.ts +0 -22
  13. package/packages/config-markdownlint/node_modules/entities/lib/encode.d.ts.map +0 -1
  14. package/packages/config-markdownlint/node_modules/entities/lib/encode.js +0 -77
  15. package/packages/config-markdownlint/node_modules/entities/lib/encode.js.map +0 -1
  16. package/packages/config-markdownlint/node_modules/entities/lib/escape.d.ts +0 -43
  17. package/packages/config-markdownlint/node_modules/entities/lib/escape.d.ts.map +0 -1
  18. package/packages/config-markdownlint/node_modules/entities/lib/escape.js +0 -122
  19. package/packages/config-markdownlint/node_modules/entities/lib/escape.js.map +0 -1
  20. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode.d.ts +0 -211
  21. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode.d.ts.map +0 -1
  22. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode.js +0 -496
  23. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode.js.map +0 -1
  24. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode_codepoint.d.ts +0 -19
  25. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode_codepoint.d.ts.map +0 -1
  26. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode_codepoint.js +0 -71
  27. package/packages/config-markdownlint/node_modules/entities/lib/esm/decode_codepoint.js.map +0 -1
  28. package/packages/config-markdownlint/node_modules/entities/lib/esm/encode.d.ts +0 -22
  29. package/packages/config-markdownlint/node_modules/entities/lib/esm/encode.d.ts.map +0 -1
  30. package/packages/config-markdownlint/node_modules/entities/lib/esm/encode.js +0 -69
  31. package/packages/config-markdownlint/node_modules/entities/lib/esm/encode.js.map +0 -1
  32. package/packages/config-markdownlint/node_modules/entities/lib/esm/escape.d.ts +0 -43
  33. package/packages/config-markdownlint/node_modules/entities/lib/esm/escape.d.ts.map +0 -1
  34. package/packages/config-markdownlint/node_modules/entities/lib/esm/escape.js +0 -116
  35. package/packages/config-markdownlint/node_modules/entities/lib/esm/escape.js.map +0 -1
  36. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-html.d.ts +0 -3
  37. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-html.d.ts.map +0 -1
  38. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-html.js +0 -7
  39. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-html.js.map +0 -1
  40. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-xml.d.ts +0 -3
  41. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-xml.d.ts.map +0 -1
  42. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-xml.js +0 -7
  43. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/decode-data-xml.js.map +0 -1
  44. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/encode-html.d.ts +0 -8
  45. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/encode-html.d.ts.map +0 -1
  46. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/encode-html.js +0 -10
  47. package/packages/config-markdownlint/node_modules/entities/lib/esm/generated/encode-html.js.map +0 -1
  48. package/packages/config-markdownlint/node_modules/entities/lib/esm/index.d.ts +0 -96
  49. package/packages/config-markdownlint/node_modules/entities/lib/esm/index.d.ts.map +0 -1
  50. package/packages/config-markdownlint/node_modules/entities/lib/esm/index.js +0 -99
  51. package/packages/config-markdownlint/node_modules/entities/lib/esm/index.js.map +0 -1
  52. package/packages/config-markdownlint/node_modules/entities/lib/esm/package.json +0 -1
  53. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-html.d.ts +0 -3
  54. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-html.d.ts.map +0 -1
  55. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-html.js +0 -9
  56. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-html.js.map +0 -1
  57. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-xml.d.ts +0 -3
  58. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-xml.d.ts.map +0 -1
  59. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-xml.js +0 -9
  60. package/packages/config-markdownlint/node_modules/entities/lib/generated/decode-data-xml.js.map +0 -1
  61. package/packages/config-markdownlint/node_modules/entities/lib/generated/encode-html.d.ts +0 -8
  62. package/packages/config-markdownlint/node_modules/entities/lib/generated/encode-html.d.ts.map +0 -1
  63. package/packages/config-markdownlint/node_modules/entities/lib/generated/encode-html.js +0 -12
  64. package/packages/config-markdownlint/node_modules/entities/lib/generated/encode-html.js.map +0 -1
  65. package/packages/config-markdownlint/node_modules/entities/lib/index.d.ts +0 -96
  66. package/packages/config-markdownlint/node_modules/entities/lib/index.d.ts.map +0 -1
  67. package/packages/config-markdownlint/node_modules/entities/lib/index.js +0 -126
  68. package/packages/config-markdownlint/node_modules/entities/lib/index.js.map +0 -1
  69. package/packages/config-markdownlint/node_modules/entities/package.json +0 -90
  70. package/packages/config-markdownlint/node_modules/entities/readme.md +0 -122
  71. package/packages/config-markdownlint/node_modules/markdown-it/LICENSE +0 -22
  72. package/packages/config-markdownlint/node_modules/markdown-it/README.md +0 -324
  73. package/packages/config-markdownlint/node_modules/markdown-it/bin/markdown-it.mjs +0 -107
  74. package/packages/config-markdownlint/node_modules/markdown-it/dist/index.cjs.js +0 -5540
  75. package/packages/config-markdownlint/node_modules/markdown-it/dist/markdown-it.js +0 -6963
  76. package/packages/config-markdownlint/node_modules/markdown-it/dist/markdown-it.min.js +0 -2
  77. package/packages/config-markdownlint/node_modules/markdown-it/index.mjs +0 -1
  78. package/packages/config-markdownlint/node_modules/markdown-it/lib/common/html_blocks.mjs +0 -67
  79. package/packages/config-markdownlint/node_modules/markdown-it/lib/common/html_re.mjs +0 -25
  80. package/packages/config-markdownlint/node_modules/markdown-it/lib/common/utils.mjs +0 -304
  81. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/index.mjs +0 -11
  82. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/parse_link_destination.mjs +0 -77
  83. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/parse_link_label.mjs +0 -49
  84. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/parse_link_title.mjs +0 -66
  85. package/packages/config-markdownlint/node_modules/markdown-it/lib/index.mjs +0 -565
  86. package/packages/config-markdownlint/node_modules/markdown-it/lib/parser_block.mjs +0 -134
  87. package/packages/config-markdownlint/node_modules/markdown-it/lib/parser_core.mjs +0 -62
  88. package/packages/config-markdownlint/node_modules/markdown-it/lib/parser_inline.mjs +0 -197
  89. package/packages/config-markdownlint/node_modules/markdown-it/lib/presets/commonmark.mjs +0 -88
  90. package/packages/config-markdownlint/node_modules/markdown-it/lib/presets/default.mjs +0 -47
  91. package/packages/config-markdownlint/node_modules/markdown-it/lib/presets/zero.mjs +0 -70
  92. package/packages/config-markdownlint/node_modules/markdown-it/lib/renderer.mjs +0 -322
  93. package/packages/config-markdownlint/node_modules/markdown-it/lib/ruler.mjs +0 -340
  94. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/blockquote.mjs +0 -209
  95. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/code.mjs +0 -30
  96. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/fence.mjs +0 -94
  97. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/heading.mjs +0 -51
  98. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/hr.mjs +0 -40
  99. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/html_block.mjs +0 -69
  100. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/lheading.mjs +0 -82
  101. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/list.mjs +0 -331
  102. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/paragraph.mjs +0 -46
  103. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/reference.mjs +0 -212
  104. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/state_block.mjs +0 -220
  105. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/table.mjs +0 -228
  106. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/block.mjs +0 -13
  107. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/inline.mjs +0 -11
  108. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/linkify.mjs +0 -134
  109. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/normalize.mjs +0 -17
  110. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/replacements.mjs +0 -101
  111. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/smartquotes.mjs +0 -193
  112. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/state_core.mjs +0 -17
  113. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/text_join.mjs +0 -43
  114. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/autolink.mjs +0 -72
  115. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/backticks.mjs +0 -60
  116. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/balance_pairs.mjs +0 -124
  117. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/emphasis.mjs +0 -123
  118. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/entity.mjs +0 -51
  119. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/escape.mjs +0 -69
  120. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/fragments_join.mjs +0 -38
  121. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/html_inline.mjs +0 -50
  122. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/image.mjs +0 -138
  123. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/link.mjs +0 -139
  124. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/linkify.mjs +0 -56
  125. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/newline.mjs +0 -42
  126. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/state_inline.mjs +0 -123
  127. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/strikethrough.mjs +0 -127
  128. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/text.mjs +0 -86
  129. package/packages/config-markdownlint/node_modules/markdown-it/lib/token.mjs +0 -191
  130. package/packages/config-markdownlint/node_modules/markdown-it/package.json +0 -92
  131. package/packages/config-markdownlint/node_modules/markdownlint/CHANGELOG.md +0 -446
  132. package/packages/config-markdownlint/node_modules/markdownlint/CONTRIBUTING.md +0 -93
  133. package/packages/config-markdownlint/node_modules/markdownlint/LICENSE +0 -21
  134. package/packages/config-markdownlint/node_modules/markdownlint/README.md +0 -1032
  135. package/packages/config-markdownlint/node_modules/markdownlint/demo/markdownlint-browser.js +0 -7116
  136. package/packages/config-markdownlint/node_modules/markdownlint/doc/CustomRules.md +0 -383
  137. package/packages/config-markdownlint/node_modules/markdownlint/doc/Prettier.md +0 -27
  138. package/packages/config-markdownlint/node_modules/markdownlint/doc/ReleaseProcess.md +0 -20
  139. package/packages/config-markdownlint/node_modules/markdownlint/doc/Rules.md +0 -2462
  140. package/packages/config-markdownlint/node_modules/markdownlint/doc/md001.md +0 -37
  141. package/packages/config-markdownlint/node_modules/markdownlint/doc/md003.md +0 -59
  142. package/packages/config-markdownlint/node_modules/markdownlint/doc/md004.md +0 -49
  143. package/packages/config-markdownlint/node_modules/markdownlint/doc/md005.md +0 -53
  144. package/packages/config-markdownlint/node_modules/markdownlint/doc/md007.md +0 -52
  145. package/packages/config-markdownlint/node_modules/markdownlint/doc/md009.md +0 -51
  146. package/packages/config-markdownlint/node_modules/markdownlint/doc/md010.md +0 -56
  147. package/packages/config-markdownlint/node_modules/markdownlint/doc/md011.md +0 -30
  148. package/packages/config-markdownlint/node_modules/markdownlint/doc/md012.md +0 -38
  149. package/packages/config-markdownlint/node_modules/markdownlint/doc/md013.md +0 -58
  150. package/packages/config-markdownlint/node_modules/markdownlint/doc/md014.md +0 -54
  151. package/packages/config-markdownlint/node_modules/markdownlint/doc/md018.md +0 -27
  152. package/packages/config-markdownlint/node_modules/markdownlint/doc/md019.md +0 -28
  153. package/packages/config-markdownlint/node_modules/markdownlint/doc/md020.md +0 -29
  154. package/packages/config-markdownlint/node_modules/markdownlint/doc/md021.md +0 -31
  155. package/packages/config-markdownlint/node_modules/markdownlint/doc/md022.md +0 -52
  156. package/packages/config-markdownlint/node_modules/markdownlint/doc/md023.md +0 -33
  157. package/packages/config-markdownlint/node_modules/markdownlint/doc/md024.md +0 -44
  158. package/packages/config-markdownlint/node_modules/markdownlint/doc/md025.md +0 -49
  159. package/packages/config-markdownlint/node_modules/markdownlint/doc/md026.md +0 -40
  160. package/packages/config-markdownlint/node_modules/markdownlint/doc/md027.md +0 -24
  161. package/packages/config-markdownlint/node_modules/markdownlint/doc/md028.md +0 -40
  162. package/packages/config-markdownlint/node_modules/markdownlint/doc/md029.md +0 -98
  163. package/packages/config-markdownlint/node_modules/markdownlint/doc/md030.md +0 -82
  164. package/packages/config-markdownlint/node_modules/markdownlint/doc/md031.md +0 -50
  165. package/packages/config-markdownlint/node_modules/markdownlint/doc/md032.md +0 -55
  166. package/packages/config-markdownlint/node_modules/markdownlint/doc/md033.md +0 -27
  167. package/packages/config-markdownlint/node_modules/markdownlint/doc/md034.md +0 -50
  168. package/packages/config-markdownlint/node_modules/markdownlint/doc/md035.md +0 -42
  169. package/packages/config-markdownlint/node_modules/markdownlint/doc/md036.md +0 -45
  170. package/packages/config-markdownlint/node_modules/markdownlint/doc/md037.md +0 -37
  171. package/packages/config-markdownlint/node_modules/markdownlint/doc/md038.md +0 -40
  172. package/packages/config-markdownlint/node_modules/markdownlint/doc/md039.md +0 -21
  173. package/packages/config-markdownlint/node_modules/markdownlint/doc/md040.md +0 -52
  174. package/packages/config-markdownlint/node_modules/markdownlint/doc/md041.md +0 -49
  175. package/packages/config-markdownlint/node_modules/markdownlint/doc/md042.md +0 -32
  176. package/packages/config-markdownlint/node_modules/markdownlint/doc/md043.md +0 -69
  177. package/packages/config-markdownlint/node_modules/markdownlint/doc/md044.md +0 -35
  178. package/packages/config-markdownlint/node_modules/markdownlint/doc/md045.md +0 -40
  179. package/packages/config-markdownlint/node_modules/markdownlint/doc/md046.md +0 -40
  180. package/packages/config-markdownlint/node_modules/markdownlint/doc/md047.md +0 -34
  181. package/packages/config-markdownlint/node_modules/markdownlint/doc/md048.md +0 -41
  182. package/packages/config-markdownlint/node_modules/markdownlint/doc/md049.md +0 -35
  183. package/packages/config-markdownlint/node_modules/markdownlint/doc/md050.md +0 -35
  184. package/packages/config-markdownlint/node_modules/markdownlint/doc/md051.md +0 -87
  185. package/packages/config-markdownlint/node_modules/markdownlint/doc/md052.md +0 -40
  186. package/packages/config-markdownlint/node_modules/markdownlint/doc/md053.md +0 -38
  187. package/packages/config-markdownlint/node_modules/markdownlint/doc/md054.md +0 -100
  188. package/packages/config-markdownlint/node_modules/markdownlint/doc/md055.md +0 -54
  189. package/packages/config-markdownlint/node_modules/markdownlint/doc/md056.md +0 -37
  190. package/packages/config-markdownlint/node_modules/markdownlint/helpers/LICENSE +0 -21
  191. package/packages/config-markdownlint/node_modules/markdownlint/helpers/README.md +0 -72
  192. package/packages/config-markdownlint/node_modules/markdownlint/helpers/helpers.js +0 -1025
  193. package/packages/config-markdownlint/node_modules/markdownlint/helpers/micromark.cjs +0 -445
  194. package/packages/config-markdownlint/node_modules/markdownlint/helpers/package.json +0 -26
  195. package/packages/config-markdownlint/node_modules/markdownlint/helpers/shared.js +0 -10
  196. package/packages/config-markdownlint/node_modules/markdownlint/lib/cache.js +0 -21
  197. package/packages/config-markdownlint/node_modules/markdownlint/lib/configuration.d.ts +0 -1178
  198. package/packages/config-markdownlint/node_modules/markdownlint/lib/constants.js +0 -14
  199. package/packages/config-markdownlint/node_modules/markdownlint/lib/markdownlint.d.ts +0 -479
  200. package/packages/config-markdownlint/node_modules/markdownlint/lib/markdownlint.js +0 -1550
  201. package/packages/config-markdownlint/node_modules/markdownlint/lib/md001.js +0 -25
  202. package/packages/config-markdownlint/node_modules/markdownlint/lib/md003.js +0 -45
  203. package/packages/config-markdownlint/node_modules/markdownlint/lib/md004.js +0 -79
  204. package/packages/config-markdownlint/node_modules/markdownlint/lib/md005.js +0 -81
  205. package/packages/config-markdownlint/node_modules/markdownlint/lib/md007.js +0 -92
  206. package/packages/config-markdownlint/node_modules/markdownlint/lib/md009.js +0 -89
  207. package/packages/config-markdownlint/node_modules/markdownlint/lib/md010.js +0 -63
  208. package/packages/config-markdownlint/node_modules/markdownlint/lib/md011.js +0 -49
  209. package/packages/config-markdownlint/node_modules/markdownlint/lib/md012.js +0 -35
  210. package/packages/config-markdownlint/node_modules/markdownlint/lib/md013.js +0 -99
  211. package/packages/config-markdownlint/node_modules/markdownlint/lib/md014.js +0 -57
  212. package/packages/config-markdownlint/node_modules/markdownlint/lib/md018.js +0 -38
  213. package/packages/config-markdownlint/node_modules/markdownlint/lib/md019.js +0 -42
  214. package/packages/config-markdownlint/node_modules/markdownlint/lib/md020.js +0 -65
  215. package/packages/config-markdownlint/node_modules/markdownlint/lib/md021.js +0 -65
  216. package/packages/config-markdownlint/node_modules/markdownlint/lib/md022.js +0 -116
  217. package/packages/config-markdownlint/node_modules/markdownlint/lib/md023.js +0 -41
  218. package/packages/config-markdownlint/node_modules/markdownlint/lib/md024.js +0 -45
  219. package/packages/config-markdownlint/node_modules/markdownlint/lib/md025.js +0 -35
  220. package/packages/config-markdownlint/node_modules/markdownlint/lib/md026.js +0 -54
  221. package/packages/config-markdownlint/node_modules/markdownlint/lib/md027.js +0 -42
  222. package/packages/config-markdownlint/node_modules/markdownlint/lib/md028.js +0 -47
  223. package/packages/config-markdownlint/node_modules/markdownlint/lib/md029.js +0 -70
  224. package/packages/config-markdownlint/node_modules/markdownlint/lib/md030.js +0 -66
  225. package/packages/config-markdownlint/node_modules/markdownlint/lib/md031.js +0 -43
  226. package/packages/config-markdownlint/node_modules/markdownlint/lib/md032.js +0 -76
  227. package/packages/config-markdownlint/node_modules/markdownlint/lib/md033.js +0 -46
  228. package/packages/config-markdownlint/node_modules/markdownlint/lib/md034.js +0 -105
  229. package/packages/config-markdownlint/node_modules/markdownlint/lib/md035.js +0 -31
  230. package/packages/config-markdownlint/node_modules/markdownlint/lib/md036.js +0 -50
  231. package/packages/config-markdownlint/node_modules/markdownlint/lib/md037.js +0 -99
  232. package/packages/config-markdownlint/node_modules/markdownlint/lib/md038.js +0 -106
  233. package/packages/config-markdownlint/node_modules/markdownlint/lib/md039.js +0 -71
  234. package/packages/config-markdownlint/node_modules/markdownlint/lib/md040.js +0 -42
  235. package/packages/config-markdownlint/node_modules/markdownlint/lib/md041.js +0 -37
  236. package/packages/config-markdownlint/node_modules/markdownlint/lib/md042.js +0 -53
  237. package/packages/config-markdownlint/node_modules/markdownlint/lib/md043.js +0 -67
  238. package/packages/config-markdownlint/node_modules/markdownlint/lib/md044.js +0 -115
  239. package/packages/config-markdownlint/node_modules/markdownlint/lib/md045.js +0 -67
  240. package/packages/config-markdownlint/node_modules/markdownlint/lib/md046.js +0 -40
  241. package/packages/config-markdownlint/node_modules/markdownlint/lib/md047.js +0 -31
  242. package/packages/config-markdownlint/node_modules/markdownlint/lib/md048.js +0 -43
  243. package/packages/config-markdownlint/node_modules/markdownlint/lib/md049-md050.js +0 -108
  244. package/packages/config-markdownlint/node_modules/markdownlint/lib/md051.js +0 -176
  245. package/packages/config-markdownlint/node_modules/markdownlint/lib/md052.js +0 -42
  246. package/packages/config-markdownlint/node_modules/markdownlint/lib/md053.js +0 -62
  247. package/packages/config-markdownlint/node_modules/markdownlint/lib/md054.js +0 -130
  248. package/packages/config-markdownlint/node_modules/markdownlint/lib/md055.js +0 -80
  249. package/packages/config-markdownlint/node_modules/markdownlint/lib/md056.js +0 -52
  250. package/packages/config-markdownlint/node_modules/markdownlint/lib/rules.js +0 -67
  251. package/packages/config-markdownlint/node_modules/markdownlint/package.json +0 -103
  252. package/packages/config-markdownlint/node_modules/markdownlint/schema/.markdownlint.jsonc +0 -304
  253. package/packages/config-markdownlint/node_modules/markdownlint/schema/.markdownlint.yaml +0 -272
  254. package/packages/config-markdownlint/node_modules/markdownlint/schema/ValidatingConfiguration.md +0 -28
  255. package/packages/config-markdownlint/node_modules/markdownlint/schema/markdownlint-config-schema.json +0 -1814
  256. package/packages/config-markdownlint/node_modules/markdownlint/style/all.json +0 -5
  257. package/packages/config-markdownlint/node_modules/markdownlint/style/cirosantilli.json +0 -22
  258. package/packages/config-markdownlint/node_modules/markdownlint/style/prettier.json +0 -26
  259. package/packages/config-markdownlint/node_modules/markdownlint/style/relaxed.json +0 -12
  260. package/packages/config-markdownlint/node_modules/markdownlint-micromark/LICENSE +0 -21
  261. package/packages/config-markdownlint/node_modules/markdownlint-micromark/README.md +0 -10
  262. package/packages/config-markdownlint/node_modules/markdownlint-micromark/micromark-browser.js +0 -2
  263. package/packages/config-markdownlint/node_modules/markdownlint-micromark/micromark-html-browser.js +0 -2
  264. package/packages/config-markdownlint/node_modules/markdownlint-micromark/micromark.cjs +0 -1
  265. package/packages/config-markdownlint/node_modules/markdownlint-micromark/micromark.d.ts +0 -1751
  266. package/packages/config-markdownlint/node_modules/markdownlint-micromark/package.json +0 -46
@@ -1,1032 +0,0 @@
1
- # markdownlint
2
-
3
- > A Node.js style checker and lint tool for Markdown/CommonMark files.
4
-
5
- [![npm version][npm-image]][npm-url]
6
- [![License][license-image]][license-url]
7
-
8
- ## Install
9
-
10
- ```bash
11
- npm install markdownlint --save-dev
12
- ```
13
-
14
- ## Overview
15
-
16
- The [Markdown](https://en.wikipedia.org/wiki/Markdown) markup language
17
- is designed to be easy to read, write, and understand. It succeeds -
18
- and its flexibility is both a benefit and a drawback. Many styles are
19
- possible, so formatting can be inconsistent. Some constructs don't
20
- work well in all parsers and should be avoided. The
21
- [CommonMark](https://commonmark.org/) specification standardizes
22
- parsers - but not authors.
23
-
24
- `markdownlint` is a
25
- [static analysis](https://en.wikipedia.org/wiki/Static_program_analysis)
26
- tool for [Node.js](https://nodejs.org/) with a library of rules
27
- to enforce standards and consistency for Markdown files. It was
28
- inspired by - and heavily influenced by - Mark Harrison's
29
- [markdownlint](https://github.com/markdownlint/markdownlint) for
30
- [Ruby](https://www.ruby-lang.org/). The initial rules, rule documentation,
31
- and test cases came directly from that project.
32
-
33
- ### Related
34
-
35
- - CLI
36
- - [markdownlint-cli][markdownlint-cli] command-line interface for Node.js
37
- ([works with pre-commit][markdownlint-cli-precommit])
38
- - [markdownlint-cli2][markdownlint-cli2] command-line interface for Node.js
39
- ([works with pre-commit][markdownlint-cli2-precommit])
40
- - GitHub
41
- - [GitHub Action for markdownlint-cli2][markdownlint-cli2-action]
42
- - [GitHub Super-Linter Action][super-linter]
43
- - [GitHub Actions problem matcher for
44
- markdownlint-cli][markdownlint-problem-matcher]
45
- - Editor
46
- - [vscode-markdownlint extension for VS Code][vscode-markdownlint]
47
- - [Sublime Text markdownlint for Sublime Text][sublimelinter]
48
- - [coc-markdownlint extension for Vim/Neovim][coc]
49
- - Tooling
50
- - [eslint-plugin-markdownlint for the ESLint analyzer][eslint-plugin]
51
- - [grunt-markdownlint for the Grunt task runner][grunt-markdownlint]
52
- - [Cake.Markdownlint addin for Cake build automation system][cake]
53
- - [Lombiq Node.js Extensions for MSBuild (.NET builds)][nodejs-extensions]
54
- - Ruby
55
- - [markdownlint/mdl gem for Ruby][rubygems-mdl]
56
-
57
- [cake]: https://github.com/cake-contrib/Cake.Markdownlint
58
- [coc]: https://github.com/fannheyward/coc-markdownlint
59
- [eslint-plugin]: https://github.com/paweldrozd/eslint-plugin-markdownlint
60
- [grunt-markdownlint]: https://github.com/sagiegurari/grunt-markdownlint
61
- [markdownlint-cli]: https://github.com/igorshubovych/markdownlint-cli
62
- [markdownlint-cli-precommit]: https://github.com/igorshubovych/markdownlint-cli#use-with-pre-commit
63
- [markdownlint-cli2]: https://github.com/DavidAnson/markdownlint-cli2
64
- [markdownlint-cli2-action]: https://github.com/marketplace/actions/markdownlint-cli2-action
65
- [markdownlint-cli2-precommit]: https://github.com/DavidAnson/markdownlint-cli2#pre-commit
66
- [markdownlint-problem-matcher]: https://github.com/xt0rted/markdownlint-problem-matcher
67
- [nodejs-extensions]: https://github.com/Lombiq/NodeJs-Extensions
68
- [rubygems-mdl]: https://rubygems.org/gems/mdl
69
- [sublimelinter]: https://packagecontrol.io/packages/SublimeLinter-contrib-markdownlint
70
- [super-linter]: https://github.com/super-linter/super-linter
71
- [vscode-markdownlint]: https://marketplace.visualstudio.com/items?itemName=DavidAnson.vscode-markdownlint
72
-
73
- ### References
74
-
75
- The following specifications are considered authoritative in cases of ambiguity:
76
-
77
- - [CommonMark](https://spec.commonmark.org/current/)
78
- - [GitHub Flavored Markdown Spec](https://github.github.com/gfm/)
79
-
80
- ## Demonstration
81
-
82
- [`markdownlint` demo](https://dlaa.me/markdownlint/), an interactive, in-browser
83
- playground for learning and exploring.
84
-
85
- ## Rules / Aliases
86
-
87
- <!-- markdownlint-disable line-length -->
88
-
89
- - **[MD001](doc/md001.md)** *heading-increment* - Heading levels should only increment by one level at a time
90
- - **[MD003](doc/md003.md)** *heading-style* - Heading style
91
- - **[MD004](doc/md004.md)** *ul-style* - Unordered list style
92
- - **[MD005](doc/md005.md)** *list-indent* - Inconsistent indentation for list items at the same level
93
- - **[MD007](doc/md007.md)** *ul-indent* - Unordered list indentation
94
- - **[MD009](doc/md009.md)** *no-trailing-spaces* - Trailing spaces
95
- - **[MD010](doc/md010.md)** *no-hard-tabs* - Hard tabs
96
- - **[MD011](doc/md011.md)** *no-reversed-links* - Reversed link syntax
97
- - **[MD012](doc/md012.md)** *no-multiple-blanks* - Multiple consecutive blank lines
98
- - **[MD013](doc/md013.md)** *line-length* - Line length
99
- - **[MD014](doc/md014.md)** *commands-show-output* - Dollar signs used before commands without showing output
100
- - **[MD018](doc/md018.md)** *no-missing-space-atx* - No space after hash on atx style heading
101
- - **[MD019](doc/md019.md)** *no-multiple-space-atx* - Multiple spaces after hash on atx style heading
102
- - **[MD020](doc/md020.md)** *no-missing-space-closed-atx* - No space inside hashes on closed atx style heading
103
- - **[MD021](doc/md021.md)** *no-multiple-space-closed-atx* - Multiple spaces inside hashes on closed atx style heading
104
- - **[MD022](doc/md022.md)** *blanks-around-headings* - Headings should be surrounded by blank lines
105
- - **[MD023](doc/md023.md)** *heading-start-left* - Headings must start at the beginning of the line
106
- - **[MD024](doc/md024.md)** *no-duplicate-heading* - Multiple headings with the same content
107
- - **[MD025](doc/md025.md)** *single-title/single-h1* - Multiple top-level headings in the same document
108
- - **[MD026](doc/md026.md)** *no-trailing-punctuation* - Trailing punctuation in heading
109
- - **[MD027](doc/md027.md)** *no-multiple-space-blockquote* - Multiple spaces after blockquote symbol
110
- - **[MD028](doc/md028.md)** *no-blanks-blockquote* - Blank line inside blockquote
111
- - **[MD029](doc/md029.md)** *ol-prefix* - Ordered list item prefix
112
- - **[MD030](doc/md030.md)** *list-marker-space* - Spaces after list markers
113
- - **[MD031](doc/md031.md)** *blanks-around-fences* - Fenced code blocks should be surrounded by blank lines
114
- - **[MD032](doc/md032.md)** *blanks-around-lists* - Lists should be surrounded by blank lines
115
- - **[MD033](doc/md033.md)** *no-inline-html* - Inline HTML
116
- - **[MD034](doc/md034.md)** *no-bare-urls* - Bare URL used
117
- - **[MD035](doc/md035.md)** *hr-style* - Horizontal rule style
118
- - **[MD036](doc/md036.md)** *no-emphasis-as-heading* - Emphasis used instead of a heading
119
- - **[MD037](doc/md037.md)** *no-space-in-emphasis* - Spaces inside emphasis markers
120
- - **[MD038](doc/md038.md)** *no-space-in-code* - Spaces inside code span elements
121
- - **[MD039](doc/md039.md)** *no-space-in-links* - Spaces inside link text
122
- - **[MD040](doc/md040.md)** *fenced-code-language* - Fenced code blocks should have a language specified
123
- - **[MD041](doc/md041.md)** *first-line-heading/first-line-h1* - First line in a file should be a top-level heading
124
- - **[MD042](doc/md042.md)** *no-empty-links* - No empty links
125
- - **[MD043](doc/md043.md)** *required-headings* - Required heading structure
126
- - **[MD044](doc/md044.md)** *proper-names* - Proper names should have the correct capitalization
127
- - **[MD045](doc/md045.md)** *no-alt-text* - Images should have alternate text (alt text)
128
- - **[MD046](doc/md046.md)** *code-block-style* - Code block style
129
- - **[MD047](doc/md047.md)** *single-trailing-newline* - Files should end with a single newline character
130
- - **[MD048](doc/md048.md)** *code-fence-style* - Code fence style
131
- - **[MD049](doc/md049.md)** *emphasis-style* - Emphasis style
132
- - **[MD050](doc/md050.md)** *strong-style* - Strong style
133
- - **[MD051](doc/md051.md)** *link-fragments* - Link fragments should be valid
134
- - **[MD052](doc/md052.md)** *reference-links-images* - Reference links and images should use a label that is defined
135
- - **[MD053](doc/md053.md)** *link-image-reference-definitions* - Link and image reference definitions should be needed
136
- - **[MD054](doc/md054.md)** *link-image-style* - Link and image style
137
- - **[MD055](doc/md055.md)** *table-pipe-style* - Table pipe style
138
- - **[MD056](doc/md056.md)** *table-column-count* - Table column count
139
-
140
- <!-- markdownlint-restore -->
141
-
142
- See [Rules.md](doc/Rules.md) for more details.
143
-
144
- ### Custom Rules
145
-
146
- In addition to built-in rules, custom rules can be used to address
147
- project-specific requirements. To find community-developed rules use
148
- [keyword `markdownlint-rule` on npm][markdownlint-rule].
149
- To implement your own rules, refer to [CustomRules.md](doc/CustomRules.md).
150
-
151
- [markdownlint-rule]: https://www.npmjs.com/search?q=keywords:markdownlint-rule
152
-
153
- ## Tags
154
-
155
- Tags group related rules and can be used to enable/disable multiple
156
- rules at once.
157
-
158
- - **`accessibility`** - `MD045`
159
- - **`atx`** - `MD018`, `MD019`
160
- - **`atx_closed`** - `MD020`, `MD021`
161
- - **`blank_lines`** - `MD012`, `MD022`, `MD031`, `MD032`, `MD047`
162
- - **`blockquote`** - `MD027`, `MD028`
163
- - **`bullet`** - `MD004`, `MD005`, `MD007`, `MD032`
164
- - **`code`** - `MD014`, `MD031`, `MD038`, `MD040`, `MD046`, `MD048`
165
- - **`emphasis`** - `MD036`, `MD037`, `MD049`, `MD050`
166
- - **`hard_tab`** - `MD010`
167
- - **`headings`** - `MD001`, `MD003`, `MD018`, `MD019`, `MD020`, `MD021`,
168
- `MD022`, `MD023`, `MD024`, `MD025`, `MD026`, `MD036`, `MD041`, `MD043`
169
- - **`hr`** - `MD035`
170
- - **`html`** - `MD033`
171
- - **`images`** - `MD045`, `MD052`, `MD053`, `MD054`
172
- - **`indentation`** - `MD005`, `MD007`, `MD027`
173
- - **`language`** - `MD040`
174
- - **`line_length`** - `MD013`
175
- - **`links`** - `MD011`, `MD034`, `MD039`, `MD042`, `MD051`, `MD052`, `MD053`,
176
- `MD054`
177
- - **`ol`** - `MD029`, `MD030`, `MD032`
178
- - **`spaces`** - `MD018`, `MD019`, `MD020`, `MD021`, `MD023`
179
- - **`spelling`** - `MD044`
180
- - **`table`** - `MD055`, `MD056`
181
- - **`ul`** - `MD004`, `MD005`, `MD007`, `MD030`, `MD032`
182
- - **`url`** - `MD034`
183
- - **`whitespace`** - `MD009`, `MD010`, `MD012`, `MD027`, `MD028`, `MD030`,
184
- `MD037`, `MD038`, `MD039`
185
-
186
- ## Configuration
187
-
188
- Text passed to `markdownlint` is parsed as Markdown, analyzed, and any
189
- issues reported. Two kinds of text are ignored by most rules:
190
-
191
- - [HTML comments](https://www.w3.org/TR/html5/syntax.html#comments)
192
- - [Front matter](https://jekyllrb.com/docs/frontmatter/) (see
193
- `options.frontMatter` below)
194
-
195
- Rules can be enabled, disabled, and configured via `options.config`
196
- (described below) to define the expected behavior for a set of inputs.
197
- To enable or disable rules at a particular location within a file, add
198
- one of these markers to the appropriate place (HTML comments don't
199
- appear in the final markup):
200
-
201
- - Disable all rules: `<!-- markdownlint-disable -->`
202
- - Enable all rules: `<!-- markdownlint-enable -->`
203
- - Disable all rules for the current line: `<!-- markdownlint-disable-line -->`
204
- - Disable all rules for the next line: `<!-- markdownlint-disable-next-line -->`
205
- - Disable one or more rules by name: `<!-- markdownlint-disable MD001 MD005 -->`
206
- - Enable one or more rules by name: `<!-- markdownlint-enable MD001 MD005 -->`
207
- - Disable one or more rules by name for the current line:
208
- `<!-- markdownlint-disable-line MD001 MD005 -->`
209
- - Disable one or more rules by name for the next line:
210
- `<!-- markdownlint-disable-next-line MD001 MD005 -->`
211
- - Capture the current rule configuration: `<!-- markdownlint-capture -->`
212
- - Restore the captured rule configuration: `<!-- markdownlint-restore -->`
213
-
214
- For example:
215
-
216
- ```markdown
217
- <!-- markdownlint-disable-next-line no-space-in-emphasis -->
218
- space * in * emphasis
219
- ```
220
-
221
- Or:
222
-
223
- ```markdown
224
- space * in * emphasis <!-- markdownlint-disable-line no-space-in-emphasis -->
225
- ```
226
-
227
- Or:
228
-
229
- ```markdown
230
- <!-- markdownlint-disable no-space-in-emphasis -->
231
- space * in * emphasis
232
- <!-- markdownlint-enable no-space-in-emphasis -->
233
- ```
234
-
235
- To temporarily disable rule(s), then restore the former configuration:
236
-
237
- ```markdown
238
- <!-- markdownlint-capture -->
239
- <!-- markdownlint-disable -->
240
- any violations you want
241
- <!-- markdownlint-restore -->
242
- ```
243
-
244
- The initial configuration is captured by default (as if every document
245
- began with `<!-- markdownlint-capture -->`), so the pattern above can
246
- be expressed more simply:
247
-
248
- ```markdown
249
- <!-- markdownlint-disable -->
250
- any violations you want
251
- <!-- markdownlint-restore -->
252
- ```
253
-
254
- Changes take effect starting with the line a comment is on, so the following
255
- has no effect:
256
-
257
- ```markdown
258
- space * in * emphasis <!-- markdownlint-disable --> <!-- markdownlint-enable -->
259
- ```
260
-
261
- To apply changes to an entire file regardless of where the comment is located,
262
- the following syntax is supported:
263
-
264
- - Disable all rules: `<!-- markdownlint-disable-file -->`
265
- - Enable all rules: `<!-- markdownlint-enable-file -->`
266
- - Disable one or more rules by name: `<!-- markdownlint-disable-file MD001 -->`
267
- - Enable one or more rules by name: `<!-- markdownlint-enable-file MD001 -->`
268
-
269
- This can be used to "hide" `markdownlint` comments at the bottom of a file.
270
-
271
- In cases where it is desirable to change the configuration of one or
272
- more rules for a file, the following more advanced syntax is supported:
273
-
274
- - Configure: `<!-- markdownlint-configure-file { options.config JSON } -->`
275
-
276
- For example:
277
-
278
- ```markdown
279
- <!-- markdownlint-configure-file { "hr-style": { "style": "---" } } -->
280
- ```
281
-
282
- or
283
-
284
- ```markdown
285
- <!-- markdownlint-configure-file
286
- {
287
- "hr-style": {
288
- "style": "---"
289
- },
290
- "no-trailing-spaces": false
291
- }
292
- -->
293
- ```
294
-
295
- These changes apply to the entire file regardless of where the comment is
296
- located. Multiple such comments (if present) are applied top-to-bottom. By
297
- default, content of `markdownlint-configure-file` is assumed to be JSON, but
298
- [`options.configParsers`](#optionsconfigparsers) can be used to support
299
- alternate formats.
300
-
301
- ## API
302
-
303
- ### Linting
304
-
305
- Standard asynchronous API:
306
-
307
- ```javascript
308
- /**
309
- * Lint specified Markdown files.
310
- *
311
- * @param {Options} options Configuration options.
312
- * @param {LintCallback} callback Callback (err, result) function.
313
- * @returns {void}
314
- */
315
- function markdownlint(options, callback) { ... }
316
- ```
317
-
318
- Synchronous API (for build scripts, etc.):
319
-
320
- ```javascript
321
- /**
322
- * Lint specified Markdown files synchronously.
323
- *
324
- * @param {Options} options Configuration options.
325
- * @returns {LintResults} Results object.
326
- */
327
- function markdownlint.sync(options) { ... }
328
- ```
329
-
330
- Promise API (in the `promises` namespace like Node.js's
331
- [`fs` Promises API](https://nodejs.org/api/fs.html#fs_fs_promises_api)):
332
-
333
- ```javascript
334
- /**
335
- * Lint specified Markdown files.
336
- *
337
- * @param {Options} options Configuration options.
338
- * @returns {Promise<LintResults>} Results object.
339
- */
340
- function markdownlint(options) { ... }
341
- ```
342
-
343
- #### options
344
-
345
- Type: `Object`
346
-
347
- Configures the function. All properties are optional, but at least one
348
- of `files` or `strings` should be set to provide input.
349
-
350
- ##### options.config
351
-
352
- Type: `Object` mapping `String` to `Boolean | Object`
353
-
354
- Configures the rules to use.
355
-
356
- Object keys are rule names or aliases and values are the rule's configuration.
357
- The value `false` disables a rule, `true` enables its default configuration,
358
- and passing an object customizes its settings. Setting the special `default`
359
- rule to `true` or `false` includes/excludes all rules by default. Enabling
360
- or disabling a tag name (ex: `whitespace`) affects all rules having that
361
- tag.
362
-
363
- The `default` rule is applied first, then keys are processed in order
364
- from top to bottom with later values overriding earlier ones. Keys
365
- (including rule names, aliases, tags, and `default`) are not case-sensitive.
366
-
367
- Example:
368
-
369
- ```json
370
- {
371
- "default": true,
372
- "MD003": { "style": "atx_closed" },
373
- "MD007": { "indent": 4 },
374
- "no-hard-tabs": false,
375
- "whitespace": false
376
- }
377
- ```
378
-
379
- See [.markdownlint.jsonc](schema/.markdownlint.jsonc) and/or
380
- [.markdownlint.yaml](schema/.markdownlint.yaml) for an example
381
- configuration object with all properties set to the default value.
382
-
383
- Sets of rules (known as a "style") can be stored separately and loaded
384
- as [JSON](https://en.wikipedia.org/wiki/JSON).
385
-
386
- Example of referencing a built-in style from JavaScript:
387
-
388
- ```javascript
389
- const options = {
390
- "files": [ "..." ],
391
- "config": require("style/relaxed.json")
392
- };
393
- ```
394
-
395
- Example doing so from `.markdownlint.json` via `extends` (more on this below):
396
-
397
- ```json
398
- {
399
- "extends": "markdownlint/style/relaxed"
400
- }
401
- ```
402
-
403
- See the [style](style) directory for more samples.
404
-
405
- See [markdownlint-config-schema.json](schema/markdownlint-config-schema.json)
406
- for the [JSON Schema](https://json-schema.org/) of the `options.config`
407
- object.
408
-
409
- See [ValidatingConfiguration.md](schema/ValidatingConfiguration.md) for ways to
410
- use the JSON Schema to validate configuration.
411
-
412
- For more advanced scenarios, styles can reference and extend other styles.
413
- The `readConfig` and `readConfigSync` functions can be used to read such
414
- styles.
415
-
416
- For example, assuming a `base.json` configuration file:
417
-
418
- ```json
419
- {
420
- "default": true
421
- }
422
- ```
423
-
424
- And a `custom.json` configuration file:
425
-
426
- ```json
427
- {
428
- "extends": "base.json",
429
- "line-length": false
430
- }
431
- ```
432
-
433
- Then code like the following:
434
-
435
- ```javascript
436
- const options = {
437
- "config": markdownlint.readConfigSync("./custom.json")
438
- };
439
- ```
440
-
441
- Merges `custom.json` and `base.json` and is equivalent to:
442
-
443
- ```javascript
444
- const options = {
445
- "config": {
446
- "default": true,
447
- "line-length": false
448
- }
449
- };
450
- ```
451
-
452
- ##### options.configParsers
453
-
454
- Type: *Optional* `Array` of `Function` taking (`String`) and returning `Object`
455
-
456
- Array of functions to parse the content of `markdownlint-configure-file` blocks.
457
-
458
- As shown in the [Configuration](#configuration) section, inline comments can be
459
- used to customize the [configuration object](#optionsconfig) for a document. By
460
- default, the `JSON.parse` built-in is used, but custom parsers can be specified.
461
- Content is passed to each parser function until one returns a value (vs.
462
- throwing an exception). As such, strict parsers should come before flexible
463
- ones.
464
-
465
- For example:
466
-
467
- ```javascript
468
- [ JSON.parse, require("toml").parse, require("js-yaml").load ]
469
- ```
470
-
471
- ##### options.customRules
472
-
473
- Type: `Array` of `Object`
474
-
475
- List of custom rules to include with the default rule set for linting.
476
-
477
- Each array element should define a rule. Rules are typically exported
478
- by another package, but can be defined locally.
479
-
480
- Example:
481
-
482
- ```javascript
483
- const extraRules = require("extraRules");
484
- const options = {
485
- "customRules": [ extraRules.one, extraRules.two ]
486
- };
487
- ```
488
-
489
- See [CustomRules.md](doc/CustomRules.md) for details about authoring
490
- custom rules.
491
-
492
- ##### options.files
493
-
494
- Type: `Array` of `String`
495
-
496
- List of files to lint.
497
-
498
- Each array element should be a single file (via relative or absolute path);
499
- [globbing](https://en.wikipedia.org/wiki/Glob_%28programming%29) is the
500
- caller's responsibility.
501
-
502
- Example: `[ "one.md", "dir/two.md" ]`
503
-
504
- ##### options.frontMatter
505
-
506
- Type: `RegExp`
507
-
508
- Matches any [front matter](https://jekyllrb.com/docs/frontmatter/)
509
- found at the beginning of a file.
510
-
511
- Some Markdown content begins with metadata; the default `RegExp` for
512
- this option ignores common forms of "front matter". To match differently,
513
- specify a custom `RegExp` or use the value `null` to disable the feature.
514
-
515
- The default value:
516
-
517
- ```javascript
518
- /((^---\s*$[\s\S]+?^---\s*)|(^\+\+\+\s*$[\s\S]+?^(\+\+\+|\.\.\.)\s*)|(^\{\s*$[\s\S]+?^\}\s*))(\r\n|\r|\n|$)/m
519
- ```
520
-
521
- Ignores [YAML](https://en.wikipedia.org/wiki/YAML),
522
- [TOML](https://en.wikipedia.org/wiki/TOML), and
523
- [JSON](https://en.wikipedia.org/wiki/JSON) front matter such as:
524
-
525
- ```text
526
- ---
527
- layout: post
528
- title: Title
529
- ---
530
- ```
531
-
532
- Note: Matches must occur at the start of the file.
533
-
534
- ##### options.fs
535
-
536
- Type: `Object` implementing the [file system API][node-fs-api]
537
-
538
- In advanced scenarios, it may be desirable to bypass the default file system
539
- API. If a custom file system implementation is provided, `markdownlint` will use
540
- that instead of invoking `require("fs")`.
541
-
542
- Note: The only methods called are `readFile` and `readFileSync`.
543
-
544
- [node-fs-api]: https://nodejs.org/api/fs.html
545
-
546
- ##### options.handleRuleFailures
547
-
548
- Type: `Boolean`
549
-
550
- Catches exceptions thrown during rule processing and reports the problem
551
- as a rule violation.
552
-
553
- By default, exceptions thrown by rules (or the library itself) are unhandled
554
- and bubble up the stack to the caller in the conventional manner. By setting
555
- `handleRuleFailures` to `true`, exceptions thrown by failing rules will
556
- be handled by the library and the exception message logged as a rule violation.
557
- This setting can be useful in the presence of (custom) rules that encounter
558
- unexpected syntax and fail. By enabling this option, the linting process
559
- is allowed to continue and report any violations that were found.
560
-
561
- ##### options.markdownItPlugins
562
-
563
- Type: `Array` of `Array` of `Function` and plugin parameters
564
-
565
- Specifies additional [markdown-it plugins][markdown-it-plugin] to use when
566
- parsing input. Plugins can be used to support additional syntax and features for
567
- advanced scenarios.
568
-
569
- [markdown-it-plugin]: https://www.npmjs.com/search?q=keywords:markdown-it-plugin
570
-
571
- Each item in the top-level `Array` should be of the form:
572
-
573
- ```javascript
574
- [ require("markdown-it-plugin"), plugin_param_0, plugin_param_1, ... ]
575
- ```
576
-
577
- ##### options.noInlineConfig
578
-
579
- Type: `Boolean`
580
-
581
- Disables the use of HTML comments like `<!-- markdownlint-enable -->` to toggle
582
- rules within the body of Markdown content.
583
-
584
- By default, properly-formatted inline comments can be used to create exceptions
585
- for parts of a document. Setting `noInlineConfig` to `true` ignores all such
586
- comments.
587
-
588
- ##### options.resultVersion
589
-
590
- Type: `Number`
591
-
592
- Specifies which version of the `result` object to return (see the "Usage"
593
- section below for examples).
594
-
595
- Passing a `resultVersion` of `0` corresponds to the original, simple format
596
- where each error is identified by rule name and line number. *This is
597
- deprecated.*
598
-
599
- Passing a `resultVersion` of `1` corresponds to a detailed format where each
600
- error includes information about the line number, rule name, alias, description,
601
- as well as any additional detail or context that is available. *This is
602
- deprecated.*
603
-
604
- Passing a `resultVersion` of `2` corresponds to a detailed format where each
605
- error includes information about the line number, rule names, description, as
606
- well as any additional detail or context that is available. *This is
607
- deprecated.*
608
-
609
- Passing a `resultVersion` of `3` corresponds to the detailed version `2` format
610
- with additional information about how to fix automatically-fixable errors. In
611
- this mode, all errors that occur on each line are reported (other versions
612
- report only the first error for each rule). *This is the default.*
613
-
614
- ##### options.strings
615
-
616
- Type: `Object` mapping `String` to `String`
617
-
618
- Map of identifiers to strings for linting.
619
-
620
- When Markdown content is not available as files, it can be passed as
621
- strings. The keys of the `strings` object are used to identify each
622
- input value in the `result` summary.
623
-
624
- Example:
625
-
626
- ```json
627
- {
628
- "readme": "# README\n...",
629
- "changelog": "# CHANGELOG\n..."
630
- }
631
- ```
632
-
633
- #### callback
634
-
635
- Type: `Function` taking (`Error`, `Object`)
636
-
637
- Standard completion callback.
638
-
639
- #### result
640
-
641
- Type: `Object`
642
-
643
- Call `result.toString()` for convenience or see below for an example of the
644
- structure of the `result` object. Passing the value `true` to `toString()`
645
- uses rule aliases (ex: `no-hard-tabs`) instead of names (ex: `MD010`).
646
-
647
- ### Config
648
-
649
- The `options.config` configuration object is simple and can be stored in a file
650
- for readability and easy reuse. The `readConfig` and `readConfigSync` functions
651
- load configuration settings and support the `extends` keyword for referencing
652
- other files (see above).
653
-
654
- By default, configuration files are parsed as JSON (and named
655
- `.markdownlint.json`). Custom parsers can be provided to handle other formats
656
- like JSONC, YAML, and TOML.
657
-
658
- Asynchronous API:
659
-
660
- ```javascript
661
- /**
662
- * Read specified configuration file.
663
- *
664
- * @param {string} file Configuration file name.
665
- * @param {ConfigurationParser[] | ReadConfigCallback} parsers Parsing function.
666
- * @param {Object} [fs] File system implementation.
667
- * @param {ReadConfigCallback} [callback] Callback (err, result) function.
668
- * @returns {void}
669
- */
670
- function readConfig(file, parsers, fs, callback) { ... }
671
- ```
672
-
673
- Synchronous API:
674
-
675
- ```javascript
676
- /**
677
- * Read specified configuration file synchronously.
678
- *
679
- * @param {string} file Configuration file name.
680
- * @param {ConfigurationParser[]} [parsers] Parsing function(s).
681
- * @param {Object} [fs] File system implementation.
682
- * @returns {Configuration} Configuration object.
683
- */
684
- function readConfigSync(file, parsers, fs) { ... }
685
- ```
686
-
687
- Promise API (in the `promises` namespace like Node.js's
688
- [`fs` Promises API](https://nodejs.org/api/fs.html#fs_promises_api)):
689
-
690
- ```javascript
691
- /**
692
- * Read specified configuration file.
693
- *
694
- * @param {string} file Configuration file name.
695
- * @param {ConfigurationParser[]} [parsers] Parsing function(s).
696
- * @param {Object} [fs] File system implementation.
697
- * @returns {Promise<Configuration>} Configuration object.
698
- */
699
- function readConfig(file, parsers, fs) { ... }
700
- ```
701
-
702
- #### file
703
-
704
- Type: `String`
705
-
706
- Location of configuration file to read.
707
-
708
- The `file` is resolved relative to the current working directory. If an
709
- `extends` key is present once read, its value will be resolved as a path
710
- relative to `file` and loaded recursively. Settings from a file referenced by
711
- `extends` are applied first, then those of `file` are applied on top (overriding
712
- any of the same keys appearing in the referenced file). If either the `file` or
713
- `extends` path begins with the `~` directory, it will act as a placeholder for
714
- the home directory.
715
-
716
- #### parsers
717
-
718
- Type: *Optional* `Array` of `Function` taking (`String`) and returning `Object`
719
-
720
- Array of functions to parse configuration files.
721
-
722
- The contents of a configuration file are passed to each parser function until
723
- one of them returns a value (vs. throwing an exception). Consequently, strict
724
- parsers should come before flexible parsers.
725
-
726
- For example:
727
-
728
- ```javascript
729
- [ JSON.parse, require("toml").parse, require("js-yaml").load ]
730
- ```
731
-
732
- #### fs
733
-
734
- Type: *Optional* `Object` implementing the [file system API][file-system-api]
735
-
736
- [file-system-api]: https://nodejs.org/api/fs.html
737
-
738
- In advanced scenarios, it may be desirable to bypass the default file system
739
- API. If a custom file system implementation is provided, `markdownlint` will use
740
- that instead of invoking `require("fs")`.
741
-
742
- Note: The only methods called are `readFile`, `readFileSync`, `access`, and
743
- `accessSync`.
744
-
745
- #### callback
746
-
747
- Type: `Function` taking (`Error`, `Object`)
748
-
749
- Standard completion callback.
750
-
751
- #### result
752
-
753
- Type: `Object`
754
-
755
- Configuration object.
756
-
757
- ## Usage
758
-
759
- Invoke `markdownlint` and use the `result` object's `toString` method:
760
-
761
- ```javascript
762
- const markdownlint = require("markdownlint");
763
-
764
- const options = {
765
- "files": [ "good.md", "bad.md" ],
766
- "strings": {
767
- "good.string": "# good.string\n\nThis string passes all rules.",
768
- "bad.string": "#bad.string\n\n#This string fails\tsome rules."
769
- }
770
- };
771
-
772
- markdownlint(options, function callback(err, result) {
773
- if (!err) {
774
- console.log(result.toString());
775
- }
776
- });
777
- ```
778
-
779
- Output:
780
-
781
- ```text
782
- bad.string: 3: MD010/no-hard-tabs Hard tabs [Column: 19]
783
- bad.string: 1: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#bad.string"]
784
- bad.string: 3: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#This string fails some rules."]
785
- bad.string: 1: MD041/first-line-heading/first-line-h1 First line in a file should be a top-level heading [Context: "#bad.string"]
786
- bad.md: 3: MD010/no-hard-tabs Hard tabs [Column: 17]
787
- bad.md: 1: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#bad.md"]
788
- bad.md: 3: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#This file fails some rules."]
789
- bad.md: 1: MD041/first-line-heading/first-line-h1 First line in a file should be a top-level heading [Context: "#bad.md"]
790
- ```
791
-
792
- Or invoke `markdownlint.sync` for a synchronous call:
793
-
794
- ```javascript
795
- const result = markdownlint.sync(options);
796
- console.log(result.toString());
797
- ```
798
-
799
- To examine the `result` object directly:
800
-
801
- ```javascript
802
- markdownlint(options, function callback(err, result) {
803
- if (!err) {
804
- console.dir(result, { "colors": true, "depth": null });
805
- }
806
- });
807
- ```
808
-
809
- Output:
810
-
811
- ```json
812
- {
813
- "good.md": [],
814
- "bad.md": [
815
- { "lineNumber": 3,
816
- "ruleNames": [ "MD010", "no-hard-tabs" ],
817
- "ruleDescription": "Hard tabs",
818
- "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/md010.md",
819
- "errorDetail": "Column: 17",
820
- "errorContext": null,
821
- "errorRange": [ 17, 1 ] },
822
- { "lineNumber": 1,
823
- "ruleNames": [ "MD018", "no-missing-space-atx" ],
824
- "ruleDescription": "No space after hash on atx style heading",
825
- "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/md018.md",
826
- "errorDetail": null,
827
- "errorContext": "#bad.md",
828
- "errorRange": [ 1, 2 ] },
829
- { "lineNumber": 3,
830
- "ruleNames": [ "MD018", "no-missing-space-atx" ],
831
- "ruleDescription": "No space after hash on atx style heading",
832
- "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/md018.md",
833
- "errorDetail": null,
834
- "errorContext": "#This file fails\tsome rules.",
835
- "errorRange": [ 1, 2 ] },
836
- { "lineNumber": 1,
837
- "ruleNames": [ "MD041", "first-line-heading", "first-line-h1" ],
838
- "ruleDescription": "First line in a file should be a top-level heading",
839
- "ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/md041.md",
840
- "errorDetail": null,
841
- "errorContext": "#bad.md",
842
- "errorRange": null }
843
- ]
844
- }
845
- ```
846
-
847
- Integration with the [gulp](https://gulpjs.com/) build system is
848
- straightforward:
849
-
850
- ```javascript
851
- const gulp = require("gulp");
852
- const through2 = require("through2");
853
- const markdownlint = require("markdownlint");
854
-
855
- gulp.task("markdownlint", function task() {
856
- return gulp.src("*.md", { "read": false })
857
- .pipe(through2.obj(function obj(file, enc, next) {
858
- markdownlint(
859
- { "files": [ file.relative ] },
860
- function callback(err, result) {
861
- const resultString = (result || "").toString();
862
- if (resultString) {
863
- console.log(resultString);
864
- }
865
- next(err, file);
866
- });
867
- }));
868
- });
869
- ```
870
-
871
- Output:
872
-
873
- ```text
874
- [00:00:00] Starting 'markdownlint'...
875
- bad.md: 3: MD010/no-hard-tabs Hard tabs [Column: 17]
876
- bad.md: 1: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#bad.md"]
877
- bad.md: 3: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#This file fails some rules."]
878
- bad.md: 1: MD041/first-line-heading/first-line-h1 First line in a file should be a top-level heading [Context: "#bad.md"]
879
- [00:00:00] Finished 'markdownlint' after 10 ms
880
- ```
881
-
882
- Integration with the [Grunt](https://gruntjs.com/) build system is similar:
883
-
884
- ```javascript
885
- const markdownlint = require("markdownlint");
886
-
887
- module.exports = function wrapper(grunt) {
888
- grunt.initConfig({
889
- "markdownlint": {
890
- "example": {
891
- "src": [ "*.md" ]
892
- }
893
- }
894
- });
895
-
896
- grunt.registerMultiTask("markdownlint", function task() {
897
- const done = this.async();
898
- markdownlint(
899
- { "files": this.filesSrc },
900
- function callback(err, result) {
901
- const resultString = err || ((result || "").toString());
902
- if (resultString) {
903
- grunt.fail.warn("\n" + resultString + "\n");
904
- }
905
- done(!err || !resultString);
906
- });
907
- });
908
- };
909
- ```
910
-
911
- Output:
912
-
913
- ```text
914
- Running "markdownlint:example" (markdownlint) task
915
- Warning:
916
- bad.md: 3: MD010/no-hard-tabs Hard tabs [Column: 17]
917
- bad.md: 1: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#bad.md"]
918
- bad.md: 3: MD018/no-missing-space-atx No space after hash on atx style heading [Context: "#This file fails some rules."]
919
- bad.md: 1: MD041/first-line-heading/first-line-h1 First line in a file should be a top-level heading [Context: "#bad.md"]
920
- Use --force to continue.
921
- ```
922
-
923
- ### Fixing
924
-
925
- Rules that can be fixed automatically include a `fixInfo` property which is
926
- outlined in the [documentation for custom rules](doc/CustomRules.md#authoring).
927
- To apply those fixes more easily, the `applyFixes` method in
928
- [markdownlint-rule-helpers](helpers/README.md#applying-recommended-fixes) may
929
- be used.
930
-
931
- ## Browser
932
-
933
- `markdownlint` also works in the browser.
934
-
935
- Generate normal and minified scripts with:
936
-
937
- ```bash
938
- npm run build-demo
939
- ```
940
-
941
- Then reference `markdown-it` and `markdownlint`:
942
-
943
- ```html
944
- <script src="demo/markdown-it.min.js"></script>
945
- <script src="demo/markdownlint-browser.min.js"></script>
946
- ```
947
-
948
- And call it like so:
949
-
950
- ```javascript
951
- const options = {
952
- "strings": {
953
- "content": "Some Markdown to lint."
954
- }
955
- };
956
- const results = window.markdownlint.sync(options).toString();
957
- ```
958
-
959
- ## Examples
960
-
961
- For ideas how to integrate `markdownlint` into your workflow, refer to the
962
- following projects or one of the tools in the [Related section](#related):
963
-
964
- - [.NET Documentation][dot-net-doc] ([Search repository][dot-net-doc-search])
965
- - [ally.js][ally-js] ([Search repository][ally-js-search])
966
- - [Apache Airflow][airflow] ([Search repository][airflow-search])
967
- - [Boostnote][boostnote] ([Search repository][boostnote-search])
968
- - [CodiMD][codimd] ([Search repository][codimd-search])
969
- - [Electron][electron] ([Search repository][electron-search])
970
- - [ESLint][eslint] ([Search repository][eslint-search])
971
- - [Garden React Components][garden] ([Search repository][garden-search])
972
- - [MDN Web Docs][mdn] ([Search repository][mdn-search])
973
- - [MkDocs][mkdocs] ([Search repository][mkdocs-search])
974
- - [Mocha][mocha] ([Search repository][mocha-search])
975
- - [Pi-hole documentation][pi-hole] ([Search repository][pi-hole-search])
976
- - [Reactable][reactable] ([Search repository][reactable-search])
977
- - [V8][v8] ([Search repository][v8-search])
978
- - [webhint][webhint] ([Search repository][webhint-search])
979
- - [webpack][webpack] ([Search repository][webpack-search])
980
- - [WordPress][wordpress] ([Search repository][wordpress-search])
981
-
982
- [ally-js]: https://allyjs.io/
983
- [ally-js-search]: https://github.com/medialize/ally.js/search?q=markdownlint
984
- [airflow]: https://airflow.apache.org
985
- [airflow-search]: https://github.com/apache/airflow/search?q=markdownlint
986
- [boostnote]: https://boostnote.io/
987
- [boostnote-search]: https://github.com/BoostIO/Boostnote/search?q=markdownlint
988
- [codimd]: https://github.com/hackmdio/codimd
989
- [codimd-search]: https://github.com/hackmdio/codimd/search?q=markdownlint
990
- [dot-net-doc]: https://docs.microsoft.com/en-us/dotnet/
991
- [dot-net-doc-search]: https://github.com/dotnet/docs/search?q=markdownlint
992
- [electron]: https://www.electronjs.org
993
- [electron-search]: https://github.com/electron/electron/search?q=markdownlint
994
- [eslint]: https://eslint.org/
995
- [eslint-search]: https://github.com/eslint/eslint/search?q=markdownlint
996
- [garden]: https://zendeskgarden.github.io/react-components/
997
- [garden-search]: https://github.com/zendeskgarden/react-components/search?q=markdownlint
998
- [mdn]: https://developer.mozilla.org/
999
- [mdn-search]: https://github.com/mdn/content/search?q=markdownlint
1000
- [mkdocs]: https://www.mkdocs.org/
1001
- [mkdocs-search]: https://github.com/mkdocs/mkdocs/search?q=markdownlint
1002
- [mocha]: https://mochajs.org/
1003
- [mocha-search]: https://github.com/mochajs/mocha/search?q=markdownlint
1004
- [pi-hole]: https://docs.pi-hole.net
1005
- [pi-hole-search]: https://github.com/pi-hole/docs/search?q=markdownlint
1006
- [reactable]: https://glittershark.github.io/reactable/
1007
- [reactable-search]: https://github.com/glittershark/reactable/search?q=markdownlint
1008
- [v8]: https://v8.dev/
1009
- [v8-search]: https://github.com/v8/v8.dev/search?q=markdownlint
1010
- [webhint]: https://webhint.io/
1011
- [webhint-search]: https://github.com/webhintio/hint/search?q=markdownlint
1012
- [webpack]: https://webpack.js.org/
1013
- [webpack-search]: https://github.com/webpack/webpack.js.org/search?q=markdownlint
1014
- [wordpress]: https://wordpress.org/gutenberg/
1015
- [wordpress-search]: https://github.com/WordPress/gutenberg/search?q=markdownlint
1016
-
1017
- ## Contributing
1018
-
1019
- See [CONTRIBUTING.md](CONTRIBUTING.md) for more information.
1020
-
1021
- ## Releasing
1022
-
1023
- See [ReleaseProcess.md](doc/ReleaseProcess.md) for more information.
1024
-
1025
- ## History
1026
-
1027
- See [CHANGELOG.md](CHANGELOG.md).
1028
-
1029
- [npm-image]: https://img.shields.io/npm/v/markdownlint.svg
1030
- [npm-url]: https://www.npmjs.com/package/markdownlint
1031
- [license-image]: https://img.shields.io/npm/l/markdownlint.svg
1032
- [license-url]: https://opensource.org/licenses/MIT