@alexlit/lint-kit 107.3.0 → 108.0.0

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 (247) hide show
  1. package/.eslintrc.cjs +7 -1
  2. package/.linthtmlrc.cjs +3 -1
  3. package/{.commitlintrc.cjs → commitlint.config.js} +1 -1
  4. package/package.json +5 -5
  5. package/packages/config-commitlint/LICENSE +20 -0
  6. package/packages/config-commitlint/README.md +5 -9
  7. package/packages/config-commitlint/index.js +1 -1
  8. package/packages/config-commitlint/package.json +4 -3
  9. package/packages/config-eslint/LICENSE +20 -0
  10. package/packages/config-eslint/index.js +12 -2
  11. package/packages/config-eslint/package.json +25 -25
  12. package/packages/config-eslint/plugins/typescript/index.js +1 -1
  13. package/packages/config-eslint/plugins/unicorn.js +2 -0
  14. package/packages/config-eslint/plugins/vue.js +34 -2
  15. package/packages/config-hooks/LICENSE +20 -0
  16. package/packages/config-hooks/README.md +18 -12
  17. package/packages/config-hooks/index.js +2 -0
  18. package/packages/config-hooks/lint-staged.js +1 -1
  19. package/packages/config-hooks/package.json +6 -5
  20. package/packages/config-htmllint/LICENSE +20 -0
  21. package/packages/config-markdownlint/LICENSE +20 -0
  22. package/packages/config-markdownlint/package.json +3 -3
  23. package/packages/config-npmlint/LICENSE +20 -0
  24. package/packages/config-npmlint/package.json +2 -2
  25. package/packages/config-prettier/LICENSE +20 -0
  26. package/packages/config-prettier/README.md +8 -3
  27. package/packages/config-prettier/index.js +14 -10
  28. package/packages/config-prettier/package.json +16 -12
  29. package/packages/config-prettier/plugins/jsdoc.js +1 -1
  30. package/packages/config-prettier/plugins/pug.js +1 -1
  31. package/packages/config-prettier/plugins/sort-json.js +1 -1
  32. package/packages/config-prettier/plugins/svelte.js +1 -1
  33. package/packages/config-prettier/plugins/tailwindcss.js +1 -1
  34. package/packages/config-prettier/plugins/xml.js +1 -1
  35. package/packages/config-stylelint/LICENSE +20 -0
  36. package/packages/config-stylelint/README.md +5 -4
  37. package/packages/config-stylelint/index.js +22 -25
  38. package/packages/config-stylelint/package.json +22 -18
  39. package/packages/config-stylelint/plugins/a11y.js +1 -1
  40. package/packages/config-stylelint/plugins/at-rule-no-children.js +1 -1
  41. package/packages/config-stylelint/plugins/color-format.js +1 -1
  42. package/packages/config-stylelint/plugins/declaration-block-no-ignored-properties.js +1 -1
  43. package/packages/config-stylelint/plugins/high-performance-animation.js +1 -1
  44. package/packages/config-stylelint/plugins/no-nested-media.js +1 -1
  45. package/packages/config-stylelint/plugins/no-unresolved-module.js +1 -1
  46. package/packages/config-stylelint/plugins/no-unsupported-browser-features.js +1 -1
  47. package/packages/config-stylelint/plugins/optional/gamut.js +1 -1
  48. package/packages/config-stylelint/plugins/optional/logical-css.js +1 -1
  49. package/packages/config-stylelint/plugins/optional/no-indistinguishable-colors.js +1 -1
  50. package/packages/config-stylelint/plugins/order.js +1 -1
  51. package/packages/config-stylelint/plugins/prettier.js +1 -1
  52. package/packages/config-stylelint/plugins/scss.js +1 -1
  53. package/packages/config-stylelint/plugins/selector-no-empty.js +1 -1
  54. package/packages/config-stylelint/plugins/use-nesting.js +1 -1
  55. package/packages/config-stylelint/plugins/vue.js +1 -1
  56. package/prettier.config.js +5 -0
  57. package/stylelint.config.js +14 -0
  58. package/.huskyrc.cjs +0 -3
  59. package/.lintstagedrc.cjs +0 -3
  60. package/.prettierrc.cjs +0 -3
  61. package/.stylelintrc.cjs +0 -4
  62. package/packages/config-hooks/husky.js +0 -6
  63. package/packages/config-markdownlint/node_modules/markdown-it/LICENSE +0 -22
  64. package/packages/config-markdownlint/node_modules/markdown-it/README.md +0 -309
  65. package/packages/config-markdownlint/node_modules/markdown-it/bin/markdown-it.js +0 -117
  66. package/packages/config-markdownlint/node_modules/markdown-it/dist/markdown-it.js +0 -8441
  67. package/packages/config-markdownlint/node_modules/markdown-it/dist/markdown-it.min.js +0 -3
  68. package/packages/config-markdownlint/node_modules/markdown-it/index.js +0 -4
  69. package/packages/config-markdownlint/node_modules/markdown-it/lib/common/entities.js +0 -6
  70. package/packages/config-markdownlint/node_modules/markdown-it/lib/common/html_blocks.js +0 -70
  71. package/packages/config-markdownlint/node_modules/markdown-it/lib/common/html_re.js +0 -28
  72. package/packages/config-markdownlint/node_modules/markdown-it/lib/common/utils.js +0 -317
  73. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/index.js +0 -7
  74. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/parse_link_destination.js +0 -80
  75. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/parse_link_label.js +0 -48
  76. package/packages/config-markdownlint/node_modules/markdown-it/lib/helpers/parse_link_title.js +0 -55
  77. package/packages/config-markdownlint/node_modules/markdown-it/lib/index.js +0 -582
  78. package/packages/config-markdownlint/node_modules/markdown-it/lib/parser_block.js +0 -131
  79. package/packages/config-markdownlint/node_modules/markdown-it/lib/parser_core.js +0 -61
  80. package/packages/config-markdownlint/node_modules/markdown-it/lib/parser_inline.js +0 -192
  81. package/packages/config-markdownlint/node_modules/markdown-it/lib/presets/commonmark.js +0 -81
  82. package/packages/config-markdownlint/node_modules/markdown-it/lib/presets/default.js +0 -41
  83. package/packages/config-markdownlint/node_modules/markdown-it/lib/presets/zero.js +0 -63
  84. package/packages/config-markdownlint/node_modules/markdown-it/lib/renderer.js +0 -341
  85. package/packages/config-markdownlint/node_modules/markdown-it/lib/ruler.js +0 -352
  86. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/blockquote.js +0 -226
  87. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/code.js +0 -34
  88. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/fence.js +0 -98
  89. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/heading.js +0 -55
  90. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/hr.js +0 -45
  91. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/html_block.js +0 -74
  92. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/lheading.js +0 -83
  93. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/list.js +0 -362
  94. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/paragraph.js +0 -51
  95. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/reference.js +0 -198
  96. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/state_block.js +0 -231
  97. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_block/table.js +0 -221
  98. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/block.js +0 -16
  99. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/inline.js +0 -13
  100. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/linkify.js +0 -142
  101. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/normalize.js +0 -21
  102. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/replacements.js +0 -105
  103. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/smartquotes.js +0 -201
  104. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/state_core.js +0 -20
  105. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_core/text_join.js +0 -45
  106. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/autolink.js +0 -76
  107. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/backticks.js +0 -63
  108. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/balance_pairs.js +0 -130
  109. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/emphasis.js +0 -130
  110. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/entity.js +0 -55
  111. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/escape.js +0 -71
  112. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/fragments_join.js +0 -41
  113. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/html_inline.js +0 -58
  114. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/image.js +0 -152
  115. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/link.js +0 -150
  116. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/linkify.js +0 -62
  117. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/newline.js +0 -46
  118. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/state_inline.js +0 -158
  119. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/strikethrough.js +0 -130
  120. package/packages/config-markdownlint/node_modules/markdown-it/lib/rules_inline/text.js +0 -89
  121. package/packages/config-markdownlint/node_modules/markdown-it/lib/token.js +0 -201
  122. package/packages/config-markdownlint/node_modules/markdown-it/package.json +0 -87
  123. package/packages/config-markdownlint/node_modules/markdownlint/CHANGELOG.md +0 -428
  124. package/packages/config-markdownlint/node_modules/markdownlint/CONTRIBUTING.md +0 -92
  125. package/packages/config-markdownlint/node_modules/markdownlint/LICENSE +0 -21
  126. package/packages/config-markdownlint/node_modules/markdownlint/README.md +0 -1026
  127. package/packages/config-markdownlint/node_modules/markdownlint/demo/markdownlint-browser.js +0 -6814
  128. package/packages/config-markdownlint/node_modules/markdownlint/doc/CustomRules.md +0 -376
  129. package/packages/config-markdownlint/node_modules/markdownlint/doc/Prettier.md +0 -27
  130. package/packages/config-markdownlint/node_modules/markdownlint/doc/ReleaseProcess.md +0 -20
  131. package/packages/config-markdownlint/node_modules/markdownlint/doc/Rules.md +0 -2335
  132. package/packages/config-markdownlint/node_modules/markdownlint/doc/md001.md +0 -37
  133. package/packages/config-markdownlint/node_modules/markdownlint/doc/md003.md +0 -59
  134. package/packages/config-markdownlint/node_modules/markdownlint/doc/md004.md +0 -49
  135. package/packages/config-markdownlint/node_modules/markdownlint/doc/md005.md +0 -53
  136. package/packages/config-markdownlint/node_modules/markdownlint/doc/md007.md +0 -52
  137. package/packages/config-markdownlint/node_modules/markdownlint/doc/md009.md +0 -51
  138. package/packages/config-markdownlint/node_modules/markdownlint/doc/md010.md +0 -56
  139. package/packages/config-markdownlint/node_modules/markdownlint/doc/md011.md +0 -30
  140. package/packages/config-markdownlint/node_modules/markdownlint/doc/md012.md +0 -38
  141. package/packages/config-markdownlint/node_modules/markdownlint/doc/md013.md +0 -57
  142. package/packages/config-markdownlint/node_modules/markdownlint/doc/md014.md +0 -54
  143. package/packages/config-markdownlint/node_modules/markdownlint/doc/md018.md +0 -27
  144. package/packages/config-markdownlint/node_modules/markdownlint/doc/md019.md +0 -28
  145. package/packages/config-markdownlint/node_modules/markdownlint/doc/md020.md +0 -29
  146. package/packages/config-markdownlint/node_modules/markdownlint/doc/md021.md +0 -31
  147. package/packages/config-markdownlint/node_modules/markdownlint/doc/md022.md +0 -52
  148. package/packages/config-markdownlint/node_modules/markdownlint/doc/md023.md +0 -33
  149. package/packages/config-markdownlint/node_modules/markdownlint/doc/md024.md +0 -47
  150. package/packages/config-markdownlint/node_modules/markdownlint/doc/md025.md +0 -49
  151. package/packages/config-markdownlint/node_modules/markdownlint/doc/md026.md +0 -40
  152. package/packages/config-markdownlint/node_modules/markdownlint/doc/md027.md +0 -24
  153. package/packages/config-markdownlint/node_modules/markdownlint/doc/md028.md +0 -40
  154. package/packages/config-markdownlint/node_modules/markdownlint/doc/md029.md +0 -98
  155. package/packages/config-markdownlint/node_modules/markdownlint/doc/md030.md +0 -82
  156. package/packages/config-markdownlint/node_modules/markdownlint/doc/md031.md +0 -50
  157. package/packages/config-markdownlint/node_modules/markdownlint/doc/md032.md +0 -55
  158. package/packages/config-markdownlint/node_modules/markdownlint/doc/md033.md +0 -27
  159. package/packages/config-markdownlint/node_modules/markdownlint/doc/md034.md +0 -50
  160. package/packages/config-markdownlint/node_modules/markdownlint/doc/md035.md +0 -42
  161. package/packages/config-markdownlint/node_modules/markdownlint/doc/md036.md +0 -45
  162. package/packages/config-markdownlint/node_modules/markdownlint/doc/md037.md +0 -37
  163. package/packages/config-markdownlint/node_modules/markdownlint/doc/md038.md +0 -40
  164. package/packages/config-markdownlint/node_modules/markdownlint/doc/md039.md +0 -21
  165. package/packages/config-markdownlint/node_modules/markdownlint/doc/md040.md +0 -52
  166. package/packages/config-markdownlint/node_modules/markdownlint/doc/md041.md +0 -49
  167. package/packages/config-markdownlint/node_modules/markdownlint/doc/md042.md +0 -32
  168. package/packages/config-markdownlint/node_modules/markdownlint/doc/md043.md +0 -69
  169. package/packages/config-markdownlint/node_modules/markdownlint/doc/md044.md +0 -35
  170. package/packages/config-markdownlint/node_modules/markdownlint/doc/md045.md +0 -40
  171. package/packages/config-markdownlint/node_modules/markdownlint/doc/md046.md +0 -40
  172. package/packages/config-markdownlint/node_modules/markdownlint/doc/md047.md +0 -34
  173. package/packages/config-markdownlint/node_modules/markdownlint/doc/md048.md +0 -41
  174. package/packages/config-markdownlint/node_modules/markdownlint/doc/md049.md +0 -32
  175. package/packages/config-markdownlint/node_modules/markdownlint/doc/md050.md +0 -32
  176. package/packages/config-markdownlint/node_modules/markdownlint/doc/md051.md +0 -61
  177. package/packages/config-markdownlint/node_modules/markdownlint/doc/md052.md +0 -40
  178. package/packages/config-markdownlint/node_modules/markdownlint/doc/md053.md +0 -38
  179. package/packages/config-markdownlint/node_modules/markdownlint/doc/md054.md +0 -100
  180. package/packages/config-markdownlint/node_modules/markdownlint/helpers/LICENSE +0 -21
  181. package/packages/config-markdownlint/node_modules/markdownlint/helpers/README.md +0 -70
  182. package/packages/config-markdownlint/node_modules/markdownlint/helpers/helpers.js +0 -1025
  183. package/packages/config-markdownlint/node_modules/markdownlint/helpers/micromark.cjs +0 -426
  184. package/packages/config-markdownlint/node_modules/markdownlint/helpers/package.json +0 -26
  185. package/packages/config-markdownlint/node_modules/markdownlint/helpers/shared.js +0 -10
  186. package/packages/config-markdownlint/node_modules/markdownlint/lib/cache.js +0 -21
  187. package/packages/config-markdownlint/node_modules/markdownlint/lib/configuration.d.ts +0 -1152
  188. package/packages/config-markdownlint/node_modules/markdownlint/lib/constants.js +0 -14
  189. package/packages/config-markdownlint/node_modules/markdownlint/lib/markdownlint.d.ts +0 -406
  190. package/packages/config-markdownlint/node_modules/markdownlint/lib/markdownlint.js +0 -1476
  191. package/packages/config-markdownlint/node_modules/markdownlint/lib/md001.js +0 -22
  192. package/packages/config-markdownlint/node_modules/markdownlint/lib/md003.js +0 -42
  193. package/packages/config-markdownlint/node_modules/markdownlint/lib/md004.js +0 -76
  194. package/packages/config-markdownlint/node_modules/markdownlint/lib/md005.js +0 -73
  195. package/packages/config-markdownlint/node_modules/markdownlint/lib/md007.js +0 -86
  196. package/packages/config-markdownlint/node_modules/markdownlint/lib/md009.js +0 -86
  197. package/packages/config-markdownlint/node_modules/markdownlint/lib/md010.js +0 -60
  198. package/packages/config-markdownlint/node_modules/markdownlint/lib/md011.js +0 -46
  199. package/packages/config-markdownlint/node_modules/markdownlint/lib/md012.js +0 -32
  200. package/packages/config-markdownlint/node_modules/markdownlint/lib/md013.js +0 -96
  201. package/packages/config-markdownlint/node_modules/markdownlint/lib/md014.js +0 -53
  202. package/packages/config-markdownlint/node_modules/markdownlint/lib/md018.js +0 -34
  203. package/packages/config-markdownlint/node_modules/markdownlint/lib/md019.js +0 -39
  204. package/packages/config-markdownlint/node_modules/markdownlint/lib/md020.js +0 -62
  205. package/packages/config-markdownlint/node_modules/markdownlint/lib/md021.js +0 -62
  206. package/packages/config-markdownlint/node_modules/markdownlint/lib/md022.js +0 -108
  207. package/packages/config-markdownlint/node_modules/markdownlint/lib/md023.js +0 -38
  208. package/packages/config-markdownlint/node_modules/markdownlint/lib/md024.js +0 -38
  209. package/packages/config-markdownlint/node_modules/markdownlint/lib/md025.js +0 -32
  210. package/packages/config-markdownlint/node_modules/markdownlint/lib/md026.js +0 -50
  211. package/packages/config-markdownlint/node_modules/markdownlint/lib/md027.js +0 -56
  212. package/packages/config-markdownlint/node_modules/markdownlint/lib/md028.js +0 -30
  213. package/packages/config-markdownlint/node_modules/markdownlint/lib/md029.js +0 -67
  214. package/packages/config-markdownlint/node_modules/markdownlint/lib/md030.js +0 -61
  215. package/packages/config-markdownlint/node_modules/markdownlint/lib/md031.js +0 -40
  216. package/packages/config-markdownlint/node_modules/markdownlint/lib/md032.js +0 -78
  217. package/packages/config-markdownlint/node_modules/markdownlint/lib/md033.js +0 -39
  218. package/packages/config-markdownlint/node_modules/markdownlint/lib/md034.js +0 -79
  219. package/packages/config-markdownlint/node_modules/markdownlint/lib/md035.js +0 -24
  220. package/packages/config-markdownlint/node_modules/markdownlint/lib/md036.js +0 -56
  221. package/packages/config-markdownlint/node_modules/markdownlint/lib/md037.js +0 -91
  222. package/packages/config-markdownlint/node_modules/markdownlint/lib/md038.js +0 -97
  223. package/packages/config-markdownlint/node_modules/markdownlint/lib/md039.js +0 -67
  224. package/packages/config-markdownlint/node_modules/markdownlint/lib/md040.js +0 -37
  225. package/packages/config-markdownlint/node_modules/markdownlint/lib/md041.js +0 -42
  226. package/packages/config-markdownlint/node_modules/markdownlint/lib/md042.js +0 -49
  227. package/packages/config-markdownlint/node_modules/markdownlint/lib/md043.js +0 -64
  228. package/packages/config-markdownlint/node_modules/markdownlint/lib/md044.js +0 -107
  229. package/packages/config-markdownlint/node_modules/markdownlint/lib/md045.js +0 -60
  230. package/packages/config-markdownlint/node_modules/markdownlint/lib/md046.js +0 -33
  231. package/packages/config-markdownlint/node_modules/markdownlint/lib/md047.js +0 -28
  232. package/packages/config-markdownlint/node_modules/markdownlint/lib/md048.js +0 -30
  233. package/packages/config-markdownlint/node_modules/markdownlint/lib/md049-md050.js +0 -89
  234. package/packages/config-markdownlint/node_modules/markdownlint/lib/md051.js +0 -172
  235. package/packages/config-markdownlint/node_modules/markdownlint/lib/md052.js +0 -39
  236. package/packages/config-markdownlint/node_modules/markdownlint/lib/md053.js +0 -59
  237. package/packages/config-markdownlint/node_modules/markdownlint/lib/md054.js +0 -125
  238. package/packages/config-markdownlint/node_modules/markdownlint/lib/rules.js +0 -65
  239. package/packages/config-markdownlint/node_modules/markdownlint/package.json +0 -109
  240. package/packages/config-markdownlint/node_modules/markdownlint/schema/.markdownlint.jsonc +0 -297
  241. package/packages/config-markdownlint/node_modules/markdownlint/schema/.markdownlint.yaml +0 -266
  242. package/packages/config-markdownlint/node_modules/markdownlint/schema/markdownlint-config-schema.json +0 -1762
  243. package/packages/config-markdownlint/node_modules/markdownlint/style/all.json +0 -5
  244. package/packages/config-markdownlint/node_modules/markdownlint/style/cirosantilli.json +0 -22
  245. package/packages/config-markdownlint/node_modules/markdownlint/style/prettier.json +0 -26
  246. package/packages/config-markdownlint/node_modules/markdownlint/style/relaxed.json +0 -12
  247. /package/packages/config-eslint/plugins/{security.js → optional/security.js} +0 -0
@@ -1,59 +0,0 @@
1
- // @ts-check
2
-
3
- "use strict";
4
-
5
- const { addError, ellipsify, linkReferenceDefinitionRe } =
6
- require("../helpers");
7
- const { referenceLinkImageData } = require("./cache");
8
-
9
- module.exports = {
10
- "names": [ "MD053", "link-image-reference-definitions" ],
11
- "description": "Link and image reference definitions should be needed",
12
- "tags": [ "images", "links" ],
13
- "function": function MD053(params, onError) {
14
- const ignored = new Set(params.config.ignored_definitions || [ "//" ]);
15
- const lines = params.lines;
16
- const { references, shortcuts, definitions, duplicateDefinitions } =
17
- referenceLinkImageData();
18
- const singleLineDefinition = (line) => (
19
- line.replace(linkReferenceDefinitionRe, "").trim().length > 0
20
- );
21
- const deleteFixInfo = {
22
- "deleteCount": -1
23
- };
24
- // Look for unused link references (unreferenced by any link/image)
25
- for (const definition of definitions.entries()) {
26
- const [ label, [ lineIndex ] ] = definition;
27
- if (
28
- !ignored.has(label) &&
29
- !references.has(label) &&
30
- !shortcuts.has(label)
31
- ) {
32
- const line = lines[lineIndex];
33
- addError(
34
- onError,
35
- lineIndex + 1,
36
- `Unused link or image reference definition: "${label}"`,
37
- ellipsify(line),
38
- [ 1, line.length ],
39
- singleLineDefinition(line) ? deleteFixInfo : 0
40
- );
41
- }
42
- }
43
- // Look for duplicate link references (defined more than once)
44
- for (const duplicateDefinition of duplicateDefinitions) {
45
- const [ label, lineIndex ] = duplicateDefinition;
46
- if (!ignored.has(label)) {
47
- const line = lines[lineIndex];
48
- addError(
49
- onError,
50
- lineIndex + 1,
51
- `Duplicate link or image reference definition: "${label}"`,
52
- ellipsify(line),
53
- [ 1, line.length ],
54
- singleLineDefinition(line) ? deleteFixInfo : 0
55
- );
56
- }
57
- }
58
- }
59
- };
@@ -1,125 +0,0 @@
1
- // @ts-check
2
-
3
- "use strict";
4
-
5
- const { addErrorContext, nextLinesRe } = require("../helpers");
6
- const { filterByTypes, filterByPredicate, getTokenTextByType } =
7
- require("../helpers/micromark.cjs");
8
- const { referenceLinkImageData } = require("./cache");
9
-
10
- const backslashEscapeRe = /\\([!"#$%&'()*+,\-./:;<=>?@[\\\]^_`{|}~])/g;
11
- const removeBackslashEscapes = (text) => text.replace(backslashEscapeRe, "$1");
12
- const autolinkDisallowedRe = /[ <>]/;
13
- const autolinkAble = (destination) => {
14
- try {
15
- // eslint-disable-next-line no-new
16
- new URL(destination);
17
- } catch {
18
- // Not an absolute URL
19
- return false;
20
- }
21
- return !autolinkDisallowedRe.test(destination);
22
- };
23
-
24
- module.exports = {
25
- "names": [ "MD054", "link-image-style" ],
26
- "description": "Link and image style",
27
- "tags": [ "images", "links" ],
28
- "function": (params, onError) => {
29
- const { parsers, config } = params;
30
- const autolink = (config.autolink === undefined) || !!config.autolink;
31
- const inline = (config.inline === undefined) || !!config.inline;
32
- const full = (config.full === undefined) || !!config.full;
33
- const collapsed = (config.collapsed === undefined) || !!config.collapsed;
34
- const shortcut = (config.shortcut === undefined) || !!config.shortcut;
35
- const urlInline = (config.url_inline === undefined) || !!config.url_inline;
36
- if (autolink && inline && full && collapsed && shortcut && urlInline) {
37
- // Everything allowed, nothing to check
38
- return;
39
- }
40
- const { definitions } = referenceLinkImageData();
41
- const links = filterByTypes(
42
- parsers.micromark.tokens,
43
- [ "autolink", "image", "link" ]
44
- );
45
- for (const link of links) {
46
- let label = null;
47
- let destination = null;
48
- const {
49
- children, endColumn, endLine, startColumn, startLine, text, type
50
- } = link;
51
- const image = (type === "image");
52
- let isError = false;
53
- if (type === "autolink") {
54
- // link kind is an autolink
55
- destination = getTokenTextByType(children, "autolinkProtocol");
56
- label = destination;
57
- isError = !autolink;
58
- } else {
59
- // link type is "image" or "link"
60
- const descendents = filterByPredicate(children);
61
- label = getTokenTextByType(descendents, "labelText");
62
- destination =
63
- getTokenTextByType(descendents, "resourceDestinationString");
64
- if (destination) {
65
- // link kind is an inline link
66
- const title = getTokenTextByType(descendents, "resourceTitleString");
67
- isError = !inline || (
68
- !urlInline &&
69
- autolink &&
70
- !image &&
71
- !title &&
72
- (label === destination) &&
73
- autolinkAble(destination)
74
- );
75
- } else {
76
- // link kind is a full/collapsed/shortcut reference link
77
- const isShortcut = !children.some((t) => t.type === "reference");
78
- const referenceString = getTokenTextByType(descendents, "referenceString");
79
- const isCollapsed = (referenceString === null);
80
- const definition = definitions.get(referenceString || label);
81
- destination = definition && definition[1];
82
- isError = destination &&
83
- (isShortcut ? !shortcut : (isCollapsed ? !collapsed : !full));
84
- }
85
- }
86
- if (isError) {
87
- let range = null;
88
- let fixInfo = null;
89
- if (startLine === endLine) {
90
- range = [ startColumn, endColumn - startColumn ];
91
- let insertText = null;
92
- const canInline = (inline && label);
93
- const canAutolink = (autolink && !image && autolinkAble(destination));
94
- if (canInline && (urlInline || !canAutolink)) {
95
- // Most useful form
96
- const prefix = (image ? "!" : "");
97
- // @ts-ignore
98
- const escapedLabel = label.replace(/[[\]]/g, "\\$&");
99
- const escapedDestination = destination.replace(/[()]/g, "\\$&");
100
- insertText = `${prefix}[${escapedLabel}](${escapedDestination})`;
101
- } else if (canAutolink) {
102
- // Simplest form
103
- insertText = `<${removeBackslashEscapes(destination)}>`;
104
- }
105
- if (insertText) {
106
- fixInfo = {
107
- "editColumn": range[0],
108
- insertText,
109
- "deleteCount": range[1]
110
- };
111
- }
112
- }
113
- addErrorContext(
114
- onError,
115
- startLine,
116
- text.replace(nextLinesRe, ""),
117
- null,
118
- null,
119
- range,
120
- fixInfo
121
- );
122
- }
123
- }
124
- }
125
- };
@@ -1,65 +0,0 @@
1
- // @ts-check
2
-
3
- "use strict";
4
-
5
- const { homepage, version } = require("./constants");
6
-
7
- const rules = [
8
- require("./md001"),
9
- require("./md003"),
10
- require("./md004"),
11
- require("./md005"),
12
- require("./md007"),
13
- require("./md009"),
14
- require("./md010"),
15
- require("./md011"),
16
- require("./md012"),
17
- require("./md013"),
18
- require("./md014"),
19
- require("./md018"),
20
- require("./md019"),
21
- require("./md020"),
22
- require("./md021"),
23
- require("./md022"),
24
- require("./md023"),
25
- require("./md024"),
26
- require("./md025"),
27
- require("./md026"),
28
- require("./md027"),
29
- require("./md028"),
30
- require("./md029"),
31
- require("./md030"),
32
- require("./md031"),
33
- require("./md032"),
34
- require("./md033"),
35
- require("./md034"),
36
- require("./md035"),
37
- require("./md036"),
38
- require("./md037"),
39
- require("./md038"),
40
- require("./md039"),
41
- require("./md040"),
42
- require("./md041"),
43
- require("./md042"),
44
- require("./md043"),
45
- require("./md044"),
46
- require("./md045"),
47
- require("./md046"),
48
- require("./md047"),
49
- require("./md048"),
50
- ...require("./md049-md050"),
51
- require("./md051"),
52
- require("./md052"),
53
- require("./md053"),
54
- require("./md054")
55
- // md055: See https://github.com/markdownlint/markdownlint
56
- // md056: See https://github.com/markdownlint/markdownlint
57
- // md057: See https://github.com/markdownlint/markdownlint
58
- ];
59
- for (const rule of rules) {
60
- const name = rule.names[0].toLowerCase();
61
- // eslint-disable-next-line dot-notation
62
- rule["information"] =
63
- new URL(`${homepage}/blob/v${version}/doc/${name}.md`);
64
- }
65
- module.exports = rules;
@@ -1,109 +0,0 @@
1
- {
2
- "name": "markdownlint",
3
- "version": "0.32.1",
4
- "description": "A Node.js style checker and lint tool for Markdown/CommonMark files.",
5
- "type": "commonjs",
6
- "main": "./lib/markdownlint.js",
7
- "exports": {
8
- ".": "./lib/markdownlint.js",
9
- "./helpers": "./helpers/helpers.js",
10
- "./style/all": "./style/all.json",
11
- "./style/cirosantilli": "./style/cirosantilli.json",
12
- "./style/prettier": "./style/prettier.json",
13
- "./style/relaxed": "./style/relaxed.json"
14
- },
15
- "types": "./lib/markdownlint.d.ts",
16
- "author": "David Anson (https://dlaa.me/)",
17
- "license": "MIT",
18
- "homepage": "https://github.com/DavidAnson/markdownlint",
19
- "repository": {
20
- "type": "git",
21
- "url": "git+https://github.com/DavidAnson/markdownlint.git"
22
- },
23
- "bugs": "https://github.com/DavidAnson/markdownlint/issues",
24
- "funding": "https://github.com/sponsors/DavidAnson",
25
- "scripts": {
26
- "build-config": "npm run build-config-schema && npm run build-config-example",
27
- "build-config-example": "node schema/build-config-example.js",
28
- "build-config-schema": "node schema/build-config-schema.js",
29
- "build-declaration": "tsc --allowJs --declaration --emitDeclarationOnly --module commonjs --resolveJsonModule --target es2015 lib/markdownlint.js && node scripts delete 'lib/{cache,constants,md,r}*.d.ts' 'micromark/*.d.cts' 'helpers/*.d.{cts,ts}'",
30
- "build-demo": "node scripts copy node_modules/markdown-it/dist/markdown-it.min.js demo/markdown-it.min.js && node scripts copy node_modules/markdownlint-micromark/micromark-browser.js demo/micromark-browser.js && node scripts copy node_modules/markdownlint-micromark/micromark-html-browser.js demo/micromark-html-browser.js && cd demo && webpack --no-stats",
31
- "build-docs": "node doc-build/build-rules.mjs",
32
- "build-example": "npm install --no-save --ignore-scripts grunt grunt-cli gulp through2",
33
- "build-micromark": "cd micromark && npm run build",
34
- "ci": "npm-run-all --continue-on-error --parallel lint serial-config-docs serial-declaration-demo test-cover && git diff --exit-code",
35
- "clone-test-repos-apache-airflow": "cd test-repos && git clone https://github.com/apache/airflow apache-airflow --depth 1 --no-tags --quiet",
36
- "clone-test-repos-dotnet-docs": "cd test-repos && git clone https://github.com/dotnet/docs dotnet-docs --depth 1 --no-tags --quiet",
37
- "clone-test-repos-electron-electron": "cd test-repos && git clone https://github.com/electron/electron electron-electron --depth 1 --no-tags --quiet && cd electron-electron && npm install --ignore-scripts @electron/lint-roller typescript@4",
38
- "clone-test-repos-eslint-eslint": "cd test-repos && git clone https://github.com/eslint/eslint eslint-eslint --depth 1 --no-tags --quiet",
39
- "clone-test-repos-mdn-content": "cd test-repos && git clone https://github.com/mdn/content mdn-content --depth 1 --no-tags --quiet",
40
- "clone-test-repos-mkdocs-mkdocs": "cd test-repos && git clone https://github.com/mkdocs/mkdocs mkdocs-mkdocs --depth 1 --no-tags --quiet",
41
- "clone-test-repos-mochajs-mocha": "cd test-repos && git clone https://github.com/mochajs/mocha mochajs-mocha --depth 1 --no-tags --quiet",
42
- "clone-test-repos-pi-hole-docs": "cd test-repos && git clone https://github.com/pi-hole/docs pi-hole-docs --depth 1 --no-tags --quiet",
43
- "clone-test-repos-v8-v8-dev": "cd test-repos && git clone https://github.com/v8/v8.dev v8-v8-dev --depth 1 --no-tags --quiet",
44
- "clone-test-repos-webhintio-hint": "cd test-repos && git clone https://github.com/webhintio/hint webhintio-hint --depth 1 --no-tags --quiet",
45
- "clone-test-repos-webpack-webpack-js-org": "cd test-repos && git clone https://github.com/webpack/webpack.js.org webpack-webpack-js-org --depth 1 --no-tags --quiet",
46
- "clone-test-repos": "mkdir test-repos && cd test-repos && npm run clone-test-repos-apache-airflow && npm run clone-test-repos-dotnet-docs && npm run clone-test-repos-electron-electron && npm run clone-test-repos-eslint-eslint && npm run clone-test-repos-mdn-content && npm run clone-test-repos-mkdocs-mkdocs && npm run clone-test-repos-mochajs-mocha && npm run clone-test-repos-pi-hole-docs && npm run clone-test-repos-v8-v8-dev && npm run clone-test-repos-webhintio-hint && npm run clone-test-repos-webpack-webpack-js-org",
47
- "declaration": "npm run build-declaration && npm run test-declaration",
48
- "example": "cd example && node standalone.js && grunt markdownlint --force && gulp markdownlint",
49
- "docker-npm-install": "docker run --rm --tty --name npm-install --volume $PWD:/home/workdir --workdir /home/workdir --user node node:latest npm install",
50
- "docker-npm-run-upgrade": "docker run --rm --tty --name npm-run-upgrade --volume $PWD:/home/workdir --workdir /home/workdir --user node node:latest npm run upgrade",
51
- "install-micromark": "cd micromark && npm install --no-package-lock",
52
- "lint": "eslint --ext .js,.cjs,.mjs --max-warnings 0 .",
53
- "lint-test-repos": "ava --timeout=10m test/markdownlint-test-repos.js",
54
- "serial-config-docs": "npm run build-config && npm run build-docs",
55
- "serial-declaration-demo": "npm run build-declaration && npm-run-all --continue-on-error --parallel build-demo test-declaration",
56
- "test": "ava --timeout=30s test/markdownlint-test.js test/markdownlint-test-config.js test/markdownlint-test-custom-rules.js test/markdownlint-test-helpers.js test/markdownlint-test-micromark.mjs test/markdownlint-test-result-object.js test/markdownlint-test-scenarios.js",
57
- "test-cover": "c8 --100 npm test",
58
- "test-declaration": "cd example/typescript && tsc && node type-check.js",
59
- "test-extra": "ava --timeout=5m test/markdownlint-test-extra-parse.js test/markdownlint-test-extra-type.js",
60
- "update-snapshots": "ava --update-snapshots test/markdownlint-test-micromark.mjs test/markdownlint-test-scenarios.js",
61
- "update-snapshots-test-repos": "ava --timeout=10m --update-snapshots test/markdownlint-test-repos.js",
62
- "upgrade": "npx --yes npm-check-updates --upgrade"
63
- },
64
- "engines": {
65
- "node": ">=18"
66
- },
67
- "dependencies": {
68
- "markdown-it": "13.0.2",
69
- "markdownlint-micromark": "0.1.7"
70
- },
71
- "devDependencies": {
72
- "@babel/core": "7.23.3",
73
- "@babel/preset-env": "7.23.3",
74
- "@hyperjump/json-schema": "1.6.5",
75
- "ava": "5.3.1",
76
- "babel-loader": "9.1.3",
77
- "c8": "8.0.1",
78
- "character-entities": "2.0.2",
79
- "eslint": "8.53.0",
80
- "eslint-plugin-es": "4.1.0",
81
- "eslint-plugin-jsdoc": "46.9.0",
82
- "eslint-plugin-n": "16.3.1",
83
- "eslint-plugin-regexp": "2.1.1",
84
- "eslint-plugin-unicorn": "49.0.0",
85
- "gemoji": "8.1.0",
86
- "globby": "14.0.0",
87
- "js-yaml": "4.1.0",
88
- "json-schema-to-typescript": "13.1.1",
89
- "markdown-it-for-inline": "0.1.1",
90
- "markdown-it-sub": "1.0.0",
91
- "markdown-it-sup": "1.0.0",
92
- "markdownlint-rule-helpers": "0.23.0",
93
- "npm-run-all": "4.1.5",
94
- "strip-json-comments": "5.0.1",
95
- "terser-webpack-plugin": "5.3.9",
96
- "toml": "3.0.0",
97
- "typescript": "5.2.2",
98
- "webpack": "5.89.0",
99
- "webpack-cli": "5.1.4",
100
- "yaml": "2.3.4"
101
- },
102
- "keywords": [
103
- "markdown",
104
- "lint",
105
- "md",
106
- "CommonMark",
107
- "markdownlint"
108
- ]
109
- }
@@ -1,297 +0,0 @@
1
- // Example markdownlint configuration with all properties set to their default value
2
- {
3
-
4
- // Default state for all rules
5
- "default": true,
6
-
7
- // Path to configuration file to extend
8
- "extends": null,
9
-
10
- // MD001/heading-increment : Heading levels should only increment by one level at a time : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md001.md
11
- "MD001": true,
12
-
13
- // MD003/heading-style : Heading style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md003.md
14
- "MD003": {
15
- // Heading style
16
- "style": "consistent"
17
- },
18
-
19
- // MD004/ul-style : Unordered list style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md004.md
20
- "MD004": {
21
- // List style
22
- "style": "consistent"
23
- },
24
-
25
- // MD005/list-indent : Inconsistent indentation for list items at the same level : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md005.md
26
- "MD005": true,
27
-
28
- // MD007/ul-indent : Unordered list indentation : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md007.md
29
- "MD007": {
30
- // Spaces for indent
31
- "indent": 2,
32
- // Whether to indent the first level of the list
33
- "start_indented": false,
34
- // Spaces for first level indent (when start_indented is set)
35
- "start_indent": 2
36
- },
37
-
38
- // MD009/no-trailing-spaces : Trailing spaces : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md009.md
39
- "MD009": {
40
- // Spaces for line break
41
- "br_spaces": 2,
42
- // Allow spaces for empty lines in list items
43
- "list_item_empty_lines": false,
44
- // Include unnecessary breaks
45
- "strict": false
46
- },
47
-
48
- // MD010/no-hard-tabs : Hard tabs : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md010.md
49
- "MD010": {
50
- // Include code blocks
51
- "code_blocks": true,
52
- // Fenced code languages to ignore
53
- "ignore_code_languages": [],
54
- // Number of spaces for each hard tab
55
- "spaces_per_tab": 1
56
- },
57
-
58
- // MD011/no-reversed-links : Reversed link syntax : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md011.md
59
- "MD011": true,
60
-
61
- // MD012/no-multiple-blanks : Multiple consecutive blank lines : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md012.md
62
- "MD012": {
63
- // Consecutive blank lines
64
- "maximum": 1
65
- },
66
-
67
- // MD013/line-length : Line length : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md013.md
68
- "MD013": {
69
- // Number of characters
70
- "line_length": 80,
71
- // Number of characters for headings
72
- "heading_line_length": 80,
73
- // Number of characters for code blocks
74
- "code_block_line_length": 80,
75
- // Include code blocks
76
- "code_blocks": true,
77
- // Include tables
78
- "tables": true,
79
- // Include headings
80
- "headings": true,
81
- // Strict length checking
82
- "strict": false,
83
- // Stern length checking
84
- "stern": false
85
- },
86
-
87
- // MD014/commands-show-output : Dollar signs used before commands without showing output : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md014.md
88
- "MD014": true,
89
-
90
- // MD018/no-missing-space-atx : No space after hash on atx style heading : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md018.md
91
- "MD018": true,
92
-
93
- // MD019/no-multiple-space-atx : Multiple spaces after hash on atx style heading : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md019.md
94
- "MD019": true,
95
-
96
- // MD020/no-missing-space-closed-atx : No space inside hashes on closed atx style heading : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md020.md
97
- "MD020": true,
98
-
99
- // MD021/no-multiple-space-closed-atx : Multiple spaces inside hashes on closed atx style heading : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md021.md
100
- "MD021": true,
101
-
102
- // MD022/blanks-around-headings : Headings should be surrounded by blank lines : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md022.md
103
- "MD022": {
104
- // Blank lines above heading
105
- "lines_above": 1,
106
- // Blank lines below heading
107
- "lines_below": 1
108
- },
109
-
110
- // MD023/heading-start-left : Headings must start at the beginning of the line : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md023.md
111
- "MD023": true,
112
-
113
- // MD024/no-duplicate-heading : Multiple headings with the same content : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md024.md
114
- "MD024": {
115
- // Only check sibling headings
116
- "allow_different_nesting": false,
117
- // Only check sibling headings
118
- "siblings_only": false
119
- },
120
-
121
- // MD025/single-title/single-h1 : Multiple top-level headings in the same document : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md025.md
122
- "MD025": {
123
- // Heading level
124
- "level": 1,
125
- // RegExp for matching title in front matter
126
- "front_matter_title": "^\\s*title\\s*[:=]"
127
- },
128
-
129
- // MD026/no-trailing-punctuation : Trailing punctuation in heading : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md026.md
130
- "MD026": {
131
- // Punctuation characters
132
- "punctuation": ".,;:!。,;:!"
133
- },
134
-
135
- // MD027/no-multiple-space-blockquote : Multiple spaces after blockquote symbol : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md027.md
136
- "MD027": true,
137
-
138
- // MD028/no-blanks-blockquote : Blank line inside blockquote : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md028.md
139
- "MD028": true,
140
-
141
- // MD029/ol-prefix : Ordered list item prefix : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md029.md
142
- "MD029": {
143
- // List style
144
- "style": "one_or_ordered"
145
- },
146
-
147
- // MD030/list-marker-space : Spaces after list markers : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md030.md
148
- "MD030": {
149
- // Spaces for single-line unordered list items
150
- "ul_single": 1,
151
- // Spaces for single-line ordered list items
152
- "ol_single": 1,
153
- // Spaces for multi-line unordered list items
154
- "ul_multi": 1,
155
- // Spaces for multi-line ordered list items
156
- "ol_multi": 1
157
- },
158
-
159
- // MD031/blanks-around-fences : Fenced code blocks should be surrounded by blank lines : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md031.md
160
- "MD031": {
161
- // Include list items
162
- "list_items": true
163
- },
164
-
165
- // MD032/blanks-around-lists : Lists should be surrounded by blank lines : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md032.md
166
- "MD032": true,
167
-
168
- // MD033/no-inline-html : Inline HTML : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md033.md
169
- "MD033": {
170
- // Allowed elements
171
- "allowed_elements": []
172
- },
173
-
174
- // MD034/no-bare-urls : Bare URL used : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md034.md
175
- "MD034": true,
176
-
177
- // MD035/hr-style : Horizontal rule style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md035.md
178
- "MD035": {
179
- // Horizontal rule style
180
- "style": "consistent"
181
- },
182
-
183
- // MD036/no-emphasis-as-heading : Emphasis used instead of a heading : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md036.md
184
- "MD036": {
185
- // Punctuation characters
186
- "punctuation": ".,;:!?。,;:!?"
187
- },
188
-
189
- // MD037/no-space-in-emphasis : Spaces inside emphasis markers : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md037.md
190
- "MD037": true,
191
-
192
- // MD038/no-space-in-code : Spaces inside code span elements : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md038.md
193
- "MD038": true,
194
-
195
- // MD039/no-space-in-links : Spaces inside link text : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md039.md
196
- "MD039": true,
197
-
198
- // MD040/fenced-code-language : Fenced code blocks should have a language specified : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md040.md
199
- "MD040": {
200
- // List of languages
201
- "allowed_languages": [],
202
- // Require language only
203
- "language_only": false
204
- },
205
-
206
- // MD041/first-line-heading/first-line-h1 : First line in a file should be a top-level heading : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md041.md
207
- "MD041": {
208
- // Heading level
209
- "level": 1,
210
- // RegExp for matching title in front matter
211
- "front_matter_title": "^\\s*title\\s*[:=]"
212
- },
213
-
214
- // MD042/no-empty-links : No empty links : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md042.md
215
- "MD042": true,
216
-
217
- // MD043/required-headings : Required heading structure : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md043.md
218
- "MD043": {
219
- // List of headings
220
- "headings": [],
221
- // Match case of headings
222
- "match_case": false
223
- },
224
-
225
- // MD044/proper-names : Proper names should have the correct capitalization : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md044.md
226
- "MD044": {
227
- // List of proper names
228
- "names": [],
229
- // Include code blocks
230
- "code_blocks": true,
231
- // Include HTML elements
232
- "html_elements": true
233
- },
234
-
235
- // MD045/no-alt-text : Images should have alternate text (alt text) : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md045.md
236
- "MD045": true,
237
-
238
- // MD046/code-block-style : Code block style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md046.md
239
- "MD046": {
240
- // Block style
241
- "style": "consistent"
242
- },
243
-
244
- // MD047/single-trailing-newline : Files should end with a single newline character : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md047.md
245
- "MD047": true,
246
-
247
- // MD048/code-fence-style : Code fence style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md048.md
248
- "MD048": {
249
- // Code fence style
250
- "style": "consistent"
251
- },
252
-
253
- // MD049/emphasis-style : Emphasis style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md049.md
254
- "MD049": {
255
- // Emphasis style
256
- "style": "consistent"
257
- },
258
-
259
- // MD050/strong-style : Strong style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md050.md
260
- "MD050": {
261
- // Strong style
262
- "style": "consistent"
263
- },
264
-
265
- // MD051/link-fragments : Link fragments should be valid : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md051.md
266
- "MD051": true,
267
-
268
- // MD052/reference-links-images : Reference links and images should use a label that is defined : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md052.md
269
- "MD052": {
270
- // Include shortcut syntax
271
- "shortcut_syntax": false
272
- },
273
-
274
- // MD053/link-image-reference-definitions : Link and image reference definitions should be needed : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md053.md
275
- "MD053": {
276
- // Ignored definitions
277
- "ignored_definitions": [
278
- "//"
279
- ]
280
- },
281
-
282
- // MD054/link-image-style : Link and image style : https://github.com/DavidAnson/markdownlint/blob/v0.32.1/doc/md054.md
283
- "MD054": {
284
- // Allow autolinks
285
- "autolink": true,
286
- // Allow inline links and images
287
- "inline": true,
288
- // Allow full reference links and images
289
- "full": true,
290
- // Allow collapsed reference links and images
291
- "collapsed": true,
292
- // Allow shortcut reference links and images
293
- "shortcut": true,
294
- // Allow URLs as inline links
295
- "url_inline": true
296
- }
297
- }