markdownlint 0.25.1 → 0.26.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 (49) hide show
  1. package/CONTRIBUTING.md +2 -0
  2. package/README.md +123 -83
  3. package/demo/markdownlint-browser.js +1716 -1269
  4. package/doc/Rules.md +133 -15
  5. package/helpers/helpers.js +427 -192
  6. package/helpers/package.json +4 -1
  7. package/lib/cache.js +15 -25
  8. package/lib/constants.js +1 -1
  9. package/lib/markdownlint.d.ts +21 -17
  10. package/lib/markdownlint.js +237 -146
  11. package/lib/md004.js +4 -4
  12. package/lib/md005.js +4 -4
  13. package/lib/md006.js +4 -4
  14. package/lib/md007.js +4 -4
  15. package/lib/md009.js +20 -13
  16. package/lib/md010.js +15 -2
  17. package/lib/md011.js +2 -2
  18. package/lib/md013.js +4 -5
  19. package/lib/md014.js +4 -4
  20. package/lib/md021.js +3 -1
  21. package/lib/md026.js +1 -1
  22. package/lib/md027.js +2 -2
  23. package/lib/md028.js +2 -2
  24. package/lib/md029.js +5 -4
  25. package/lib/md030.js +4 -4
  26. package/lib/md031.js +2 -2
  27. package/lib/md032.js +3 -2
  28. package/lib/md033.js +2 -3
  29. package/lib/md034.js +2 -2
  30. package/lib/md035.js +7 -2
  31. package/lib/md036.js +2 -2
  32. package/lib/md038.js +7 -4
  33. package/lib/md039.js +6 -4
  34. package/lib/md042.js +17 -10
  35. package/lib/md043.js +2 -2
  36. package/lib/md044.js +20 -9
  37. package/lib/md046.js +14 -13
  38. package/lib/md048.js +13 -14
  39. package/lib/md049-md050.js +73 -0
  40. package/lib/md051.js +84 -0
  41. package/lib/md052.js +35 -0
  42. package/lib/md053.js +52 -0
  43. package/lib/rules.js +6 -4
  44. package/package.json +19 -16
  45. package/schema/.markdownlint.jsonc +15 -2
  46. package/schema/.markdownlint.yaml +14 -1
  47. package/schema/markdownlint-config-schema.json +119 -737
  48. package/lib/md049.js +0 -45
  49. package/lib/md050.js +0 -45
@@ -26,14 +26,10 @@
26
26
  "default": true
27
27
  },
28
28
  "heading-increment": {
29
- "description": "MD001/heading-increment/header-increment - Heading levels should only increment by one level at a time",
30
- "type": "boolean",
31
- "default": true
29
+ "$ref": "#/properties/MD001"
32
30
  },
33
31
  "header-increment": {
34
- "description": "MD001/heading-increment/header-increment - Heading levels should only increment by one level at a time",
35
- "type": "boolean",
36
- "default": true
32
+ "$ref": "#/properties/MD001"
37
33
  },
38
34
  "MD002": {
39
35
  "description": "MD002/first-heading-h1/first-header-h1 - First heading should be a top-level heading",
@@ -46,42 +42,18 @@
46
42
  "level": {
47
43
  "description": "Heading level",
48
44
  "type": "integer",
45
+ "minimum": 1,
46
+ "maximum": 6,
49
47
  "default": 1
50
48
  }
51
49
  },
52
50
  "additionalProperties": false
53
51
  },
54
52
  "first-heading-h1": {
55
- "description": "MD002/first-heading-h1/first-header-h1 - First heading should be a top-level heading",
56
- "type": [
57
- "boolean",
58
- "object"
59
- ],
60
- "default": true,
61
- "properties": {
62
- "level": {
63
- "description": "Heading level",
64
- "type": "integer",
65
- "default": 1
66
- }
67
- },
68
- "additionalProperties": false
53
+ "$ref": "#/properties/MD002"
69
54
  },
70
55
  "first-header-h1": {
71
- "description": "MD002/first-heading-h1/first-header-h1 - First heading should be a top-level heading",
72
- "type": [
73
- "boolean",
74
- "object"
75
- ],
76
- "default": true,
77
- "properties": {
78
- "level": {
79
- "description": "Heading level",
80
- "type": "integer",
81
- "default": 1
82
- }
83
- },
84
- "additionalProperties": false
56
+ "$ref": "#/properties/MD002"
85
57
  },
86
58
  "MD003": {
87
59
  "description": "MD003/heading-style/header-style - Heading style",
@@ -108,52 +80,10 @@
108
80
  "additionalProperties": false
109
81
  },
110
82
  "heading-style": {
111
- "description": "MD003/heading-style/header-style - Heading style",
112
- "type": [
113
- "boolean",
114
- "object"
115
- ],
116
- "default": true,
117
- "properties": {
118
- "style": {
119
- "description": "Heading style",
120
- "type": "string",
121
- "enum": [
122
- "consistent",
123
- "atx",
124
- "atx_closed",
125
- "setext",
126
- "setext_with_atx",
127
- "setext_with_atx_closed"
128
- ],
129
- "default": "consistent"
130
- }
131
- },
132
- "additionalProperties": false
83
+ "$ref": "#/properties/MD003"
133
84
  },
134
85
  "header-style": {
135
- "description": "MD003/heading-style/header-style - Heading style",
136
- "type": [
137
- "boolean",
138
- "object"
139
- ],
140
- "default": true,
141
- "properties": {
142
- "style": {
143
- "description": "Heading style",
144
- "type": "string",
145
- "enum": [
146
- "consistent",
147
- "atx",
148
- "atx_closed",
149
- "setext",
150
- "setext_with_atx",
151
- "setext_with_atx_closed"
152
- ],
153
- "default": "consistent"
154
- }
155
- },
156
- "additionalProperties": false
86
+ "$ref": "#/properties/MD003"
157
87
  },
158
88
  "MD004": {
159
89
  "description": "MD004/ul-style - Unordered list style",
@@ -179,27 +109,7 @@
179
109
  "additionalProperties": false
180
110
  },
181
111
  "ul-style": {
182
- "description": "MD004/ul-style - Unordered list style",
183
- "type": [
184
- "boolean",
185
- "object"
186
- ],
187
- "default": true,
188
- "properties": {
189
- "style": {
190
- "description": "List style",
191
- "type": "string",
192
- "enum": [
193
- "consistent",
194
- "asterisk",
195
- "plus",
196
- "dash",
197
- "sublist"
198
- ],
199
- "default": "consistent"
200
- }
201
- },
202
- "additionalProperties": false
112
+ "$ref": "#/properties/MD004"
203
113
  },
204
114
  "MD005": {
205
115
  "description": "MD005/list-indent - Inconsistent indentation for list items at the same level",
@@ -207,9 +117,7 @@
207
117
  "default": true
208
118
  },
209
119
  "list-indent": {
210
- "description": "MD005/list-indent - Inconsistent indentation for list items at the same level",
211
- "type": "boolean",
212
- "default": true
120
+ "$ref": "#/properties/MD005"
213
121
  },
214
122
  "MD006": {
215
123
  "description": "MD006/ul-start-left - Consider starting bulleted lists at the beginning of the line",
@@ -217,9 +125,7 @@
217
125
  "default": true
218
126
  },
219
127
  "ul-start-left": {
220
- "description": "MD006/ul-start-left - Consider starting bulleted lists at the beginning of the line",
221
- "type": "boolean",
222
- "default": true
128
+ "$ref": "#/properties/MD006"
223
129
  },
224
130
  "MD007": {
225
131
  "description": "MD007/ul-indent - Unordered list indentation",
@@ -232,6 +138,7 @@
232
138
  "indent": {
233
139
  "description": "Spaces for indent",
234
140
  "type": "integer",
141
+ "minimum": 1,
235
142
  "default": 2
236
143
  },
237
144
  "start_indented": {
@@ -242,36 +149,14 @@
242
149
  "start_indent": {
243
150
  "description": "Spaces for first level indent (when start_indented is set)",
244
151
  "type": "integer",
152
+ "minimum": 1,
245
153
  "default": 2
246
154
  }
247
155
  },
248
156
  "additionalProperties": false
249
157
  },
250
158
  "ul-indent": {
251
- "description": "MD007/ul-indent - Unordered list indentation",
252
- "type": [
253
- "boolean",
254
- "object"
255
- ],
256
- "default": true,
257
- "properties": {
258
- "indent": {
259
- "description": "Spaces for indent",
260
- "type": "integer",
261
- "default": 2
262
- },
263
- "start_indented": {
264
- "description": "Whether to indent the first level of the list",
265
- "type": "boolean",
266
- "default": false
267
- },
268
- "start_indent": {
269
- "description": "Spaces for first level indent (when start_indented is set)",
270
- "type": "integer",
271
- "default": 2
272
- }
273
- },
274
- "additionalProperties": false
159
+ "$ref": "#/properties/MD007"
275
160
  },
276
161
  "MD009": {
277
162
  "description": "MD009/no-trailing-spaces - Trailing spaces",
@@ -284,6 +169,7 @@
284
169
  "br_spaces": {
285
170
  "description": "Spaces for line break",
286
171
  "type": "integer",
172
+ "minimum": 0,
287
173
  "default": 2
288
174
  },
289
175
  "list_item_empty_lines": {
@@ -300,30 +186,7 @@
300
186
  "additionalProperties": false
301
187
  },
302
188
  "no-trailing-spaces": {
303
- "description": "MD009/no-trailing-spaces - Trailing spaces",
304
- "type": [
305
- "boolean",
306
- "object"
307
- ],
308
- "default": true,
309
- "properties": {
310
- "br_spaces": {
311
- "description": "Spaces for line break",
312
- "type": "integer",
313
- "default": 2
314
- },
315
- "list_item_empty_lines": {
316
- "description": "Allow spaces for empty lines in list items",
317
- "type": "boolean",
318
- "default": false
319
- },
320
- "strict": {
321
- "description": "Include unnecessary breaks",
322
- "type": "boolean",
323
- "default": false
324
- }
325
- },
326
- "additionalProperties": false
189
+ "$ref": "#/properties/MD009"
327
190
  },
328
191
  "MD010": {
329
192
  "description": "MD010/no-hard-tabs - Hard tabs",
@@ -338,34 +201,25 @@
338
201
  "type": "boolean",
339
202
  "default": true
340
203
  },
204
+ "ignore_code_languages": {
205
+ "description": "Fenced code languages to ignore",
206
+ "type": "array",
207
+ "items": {
208
+ "type": "string"
209
+ },
210
+ "default": []
211
+ },
341
212
  "spaces_per_tab": {
342
213
  "description": "Number of spaces for each hard tab",
343
- "type": "number",
214
+ "type": "integer",
215
+ "minimum": 0,
344
216
  "default": 1
345
217
  }
346
218
  },
347
219
  "additionalProperties": false
348
220
  },
349
221
  "no-hard-tabs": {
350
- "description": "MD010/no-hard-tabs - Hard tabs",
351
- "type": [
352
- "boolean",
353
- "object"
354
- ],
355
- "default": true,
356
- "properties": {
357
- "code_blocks": {
358
- "description": "Include code blocks",
359
- "type": "boolean",
360
- "default": true
361
- },
362
- "spaces_per_tab": {
363
- "description": "Number of spaces for each hard tab",
364
- "type": "number",
365
- "default": 1
366
- }
367
- },
368
- "additionalProperties": false
222
+ "$ref": "#/properties/MD010"
369
223
  },
370
224
  "MD011": {
371
225
  "description": "MD011/no-reversed-links - Reversed link syntax",
@@ -373,9 +227,7 @@
373
227
  "default": true
374
228
  },
375
229
  "no-reversed-links": {
376
- "description": "MD011/no-reversed-links - Reversed link syntax",
377
- "type": "boolean",
378
- "default": true
230
+ "$ref": "#/properties/MD011"
379
231
  },
380
232
  "MD012": {
381
233
  "description": "MD012/no-multiple-blanks - Multiple consecutive blank lines",
@@ -388,26 +240,14 @@
388
240
  "maximum": {
389
241
  "description": "Consecutive blank lines",
390
242
  "type": "integer",
243
+ "minimum": 1,
391
244
  "default": 1
392
245
  }
393
246
  },
394
247
  "additionalProperties": false
395
248
  },
396
249
  "no-multiple-blanks": {
397
- "description": "MD012/no-multiple-blanks - Multiple consecutive blank lines",
398
- "type": [
399
- "boolean",
400
- "object"
401
- ],
402
- "default": true,
403
- "properties": {
404
- "maximum": {
405
- "description": "Consecutive blank lines",
406
- "type": "integer",
407
- "default": 1
408
- }
409
- },
410
- "additionalProperties": false
250
+ "$ref": "#/properties/MD012"
411
251
  },
412
252
  "MD013": {
413
253
  "description": "MD013/line-length - Line length",
@@ -420,16 +260,19 @@
420
260
  "line_length": {
421
261
  "description": "Number of characters",
422
262
  "type": "integer",
263
+ "minimum": 1,
423
264
  "default": 80
424
265
  },
425
266
  "heading_line_length": {
426
267
  "description": "Number of characters for headings",
427
268
  "type": "integer",
269
+ "minimum": 1,
428
270
  "default": 80
429
271
  },
430
272
  "code_block_line_length": {
431
273
  "description": "Number of characters for code blocks",
432
274
  "type": "integer",
275
+ "minimum": 1,
433
276
  "default": 80
434
277
  },
435
278
  "code_blocks": {
@@ -466,60 +309,7 @@
466
309
  "additionalProperties": false
467
310
  },
468
311
  "line-length": {
469
- "description": "MD013/line-length - Line length",
470
- "type": [
471
- "boolean",
472
- "object"
473
- ],
474
- "default": true,
475
- "properties": {
476
- "line_length": {
477
- "description": "Number of characters",
478
- "type": "integer",
479
- "default": 80
480
- },
481
- "heading_line_length": {
482
- "description": "Number of characters for headings",
483
- "type": "integer",
484
- "default": 80
485
- },
486
- "code_block_line_length": {
487
- "description": "Number of characters for code blocks",
488
- "type": "integer",
489
- "default": 80
490
- },
491
- "code_blocks": {
492
- "description": "Include code blocks",
493
- "type": "boolean",
494
- "default": true
495
- },
496
- "tables": {
497
- "description": "Include tables",
498
- "type": "boolean",
499
- "default": true
500
- },
501
- "headings": {
502
- "description": "Include headings",
503
- "type": "boolean",
504
- "default": true
505
- },
506
- "headers": {
507
- "description": "Include headings",
508
- "type": "boolean",
509
- "default": true
510
- },
511
- "strict": {
512
- "description": "Strict length checking",
513
- "type": "boolean",
514
- "default": false
515
- },
516
- "stern": {
517
- "description": "Stern length checking",
518
- "type": "boolean",
519
- "default": false
520
- }
521
- },
522
- "additionalProperties": false
312
+ "$ref": "#/properties/MD013"
523
313
  },
524
314
  "MD014": {
525
315
  "description": "MD014/commands-show-output - Dollar signs used before commands without showing output",
@@ -527,9 +317,7 @@
527
317
  "default": true
528
318
  },
529
319
  "commands-show-output": {
530
- "description": "MD014/commands-show-output - Dollar signs used before commands without showing output",
531
- "type": "boolean",
532
- "default": true
320
+ "$ref": "#/properties/MD014"
533
321
  },
534
322
  "MD018": {
535
323
  "description": "MD018/no-missing-space-atx - No space after hash on atx style heading",
@@ -537,9 +325,7 @@
537
325
  "default": true
538
326
  },
539
327
  "no-missing-space-atx": {
540
- "description": "MD018/no-missing-space-atx - No space after hash on atx style heading",
541
- "type": "boolean",
542
- "default": true
328
+ "$ref": "#/properties/MD018"
543
329
  },
544
330
  "MD019": {
545
331
  "description": "MD019/no-multiple-space-atx - Multiple spaces after hash on atx style heading",
@@ -547,9 +333,7 @@
547
333
  "default": true
548
334
  },
549
335
  "no-multiple-space-atx": {
550
- "description": "MD019/no-multiple-space-atx - Multiple spaces after hash on atx style heading",
551
- "type": "boolean",
552
- "default": true
336
+ "$ref": "#/properties/MD019"
553
337
  },
554
338
  "MD020": {
555
339
  "description": "MD020/no-missing-space-closed-atx - No space inside hashes on closed atx style heading",
@@ -557,9 +341,7 @@
557
341
  "default": true
558
342
  },
559
343
  "no-missing-space-closed-atx": {
560
- "description": "MD020/no-missing-space-closed-atx - No space inside hashes on closed atx style heading",
561
- "type": "boolean",
562
- "default": true
344
+ "$ref": "#/properties/MD020"
563
345
  },
564
346
  "MD021": {
565
347
  "description": "MD021/no-multiple-space-closed-atx - Multiple spaces inside hashes on closed atx style heading",
@@ -567,9 +349,7 @@
567
349
  "default": true
568
350
  },
569
351
  "no-multiple-space-closed-atx": {
570
- "description": "MD021/no-multiple-space-closed-atx - Multiple spaces inside hashes on closed atx style heading",
571
- "type": "boolean",
572
- "default": true
352
+ "$ref": "#/properties/MD021"
573
353
  },
574
354
  "MD022": {
575
355
  "description": "MD022/blanks-around-headings/blanks-around-headers - Headings should be surrounded by blank lines",
@@ -582,57 +362,23 @@
582
362
  "lines_above": {
583
363
  "description": "Blank lines above heading",
584
364
  "type": "integer",
365
+ "minimum": 0,
585
366
  "default": 1
586
367
  },
587
368
  "lines_below": {
588
369
  "description": "Blank lines below heading",
589
370
  "type": "integer",
371
+ "minimum": 0,
590
372
  "default": 1
591
373
  }
592
374
  },
593
375
  "additionalProperties": false
594
376
  },
595
377
  "blanks-around-headings": {
596
- "description": "MD022/blanks-around-headings/blanks-around-headers - Headings should be surrounded by blank lines",
597
- "type": [
598
- "boolean",
599
- "object"
600
- ],
601
- "default": true,
602
- "properties": {
603
- "lines_above": {
604
- "description": "Blank lines above heading",
605
- "type": "integer",
606
- "default": 1
607
- },
608
- "lines_below": {
609
- "description": "Blank lines below heading",
610
- "type": "integer",
611
- "default": 1
612
- }
613
- },
614
- "additionalProperties": false
378
+ "$ref": "#/properties/MD022"
615
379
  },
616
380
  "blanks-around-headers": {
617
- "description": "MD022/blanks-around-headings/blanks-around-headers - Headings should be surrounded by blank lines",
618
- "type": [
619
- "boolean",
620
- "object"
621
- ],
622
- "default": true,
623
- "properties": {
624
- "lines_above": {
625
- "description": "Blank lines above heading",
626
- "type": "integer",
627
- "default": 1
628
- },
629
- "lines_below": {
630
- "description": "Blank lines below heading",
631
- "type": "integer",
632
- "default": 1
633
- }
634
- },
635
- "additionalProperties": false
381
+ "$ref": "#/properties/MD022"
636
382
  },
637
383
  "MD023": {
638
384
  "description": "MD023/heading-start-left/header-start-left - Headings must start at the beginning of the line",
@@ -640,14 +386,10 @@
640
386
  "default": true
641
387
  },
642
388
  "heading-start-left": {
643
- "description": "MD023/heading-start-left/header-start-left - Headings must start at the beginning of the line",
644
- "type": "boolean",
645
- "default": true
389
+ "$ref": "#/properties/MD023"
646
390
  },
647
391
  "header-start-left": {
648
- "description": "MD023/heading-start-left/header-start-left - Headings must start at the beginning of the line",
649
- "type": "boolean",
650
- "default": true
392
+ "$ref": "#/properties/MD023"
651
393
  },
652
394
  "MD024": {
653
395
  "description": "MD024/no-duplicate-heading/no-duplicate-header - Multiple headings with the same content",
@@ -671,46 +413,10 @@
671
413
  "additionalProperties": false
672
414
  },
673
415
  "no-duplicate-heading": {
674
- "description": "MD024/no-duplicate-heading/no-duplicate-header - Multiple headings with the same content",
675
- "type": [
676
- "boolean",
677
- "object"
678
- ],
679
- "default": true,
680
- "properties": {
681
- "allow_different_nesting": {
682
- "description": "Only check sibling headings",
683
- "type": "boolean",
684
- "default": false
685
- },
686
- "siblings_only": {
687
- "description": "Only check sibling headings",
688
- "type": "boolean",
689
- "default": false
690
- }
691
- },
692
- "additionalProperties": false
416
+ "$ref": "#/properties/MD024"
693
417
  },
694
418
  "no-duplicate-header": {
695
- "description": "MD024/no-duplicate-heading/no-duplicate-header - Multiple headings with the same content",
696
- "type": [
697
- "boolean",
698
- "object"
699
- ],
700
- "default": true,
701
- "properties": {
702
- "allow_different_nesting": {
703
- "description": "Only check sibling headings",
704
- "type": "boolean",
705
- "default": false
706
- },
707
- "siblings_only": {
708
- "description": "Only check sibling headings",
709
- "type": "boolean",
710
- "default": false
711
- }
712
- },
713
- "additionalProperties": false
419
+ "$ref": "#/properties/MD024"
714
420
  },
715
421
  "MD025": {
716
422
  "description": "MD025/single-title/single-h1 - Multiple top-level headings in the same document",
@@ -723,6 +429,8 @@
723
429
  "level": {
724
430
  "description": "Heading level",
725
431
  "type": "integer",
432
+ "minimum": 1,
433
+ "maximum": 6,
726
434
  "default": 1
727
435
  },
728
436
  "front_matter_title": {
@@ -734,46 +442,10 @@
734
442
  "additionalProperties": false
735
443
  },
736
444
  "single-title": {
737
- "description": "MD025/single-title/single-h1 - Multiple top-level headings in the same document",
738
- "type": [
739
- "boolean",
740
- "object"
741
- ],
742
- "default": true,
743
- "properties": {
744
- "level": {
745
- "description": "Heading level",
746
- "type": "integer",
747
- "default": 1
748
- },
749
- "front_matter_title": {
750
- "description": "RegExp for matching title in front matter",
751
- "type": "string",
752
- "default": "^\\s*title\\s*[:=]"
753
- }
754
- },
755
- "additionalProperties": false
445
+ "$ref": "#/properties/MD025"
756
446
  },
757
447
  "single-h1": {
758
- "description": "MD025/single-title/single-h1 - Multiple top-level headings in the same document",
759
- "type": [
760
- "boolean",
761
- "object"
762
- ],
763
- "default": true,
764
- "properties": {
765
- "level": {
766
- "description": "Heading level",
767
- "type": "integer",
768
- "default": 1
769
- },
770
- "front_matter_title": {
771
- "description": "RegExp for matching title in front matter",
772
- "type": "string",
773
- "default": "^\\s*title\\s*[:=]"
774
- }
775
- },
776
- "additionalProperties": false
448
+ "$ref": "#/properties/MD025"
777
449
  },
778
450
  "MD026": {
779
451
  "description": "MD026/no-trailing-punctuation - Trailing punctuation in heading",
@@ -792,20 +464,7 @@
792
464
  "additionalProperties": false
793
465
  },
794
466
  "no-trailing-punctuation": {
795
- "description": "MD026/no-trailing-punctuation - Trailing punctuation in heading",
796
- "type": [
797
- "boolean",
798
- "object"
799
- ],
800
- "default": true,
801
- "properties": {
802
- "punctuation": {
803
- "description": "Punctuation characters",
804
- "type": "string",
805
- "default": ".,;:!。,;:!"
806
- }
807
- },
808
- "additionalProperties": false
467
+ "$ref": "#/properties/MD026"
809
468
  },
810
469
  "MD027": {
811
470
  "description": "MD027/no-multiple-space-blockquote - Multiple spaces after blockquote symbol",
@@ -813,9 +472,7 @@
813
472
  "default": true
814
473
  },
815
474
  "no-multiple-space-blockquote": {
816
- "description": "MD027/no-multiple-space-blockquote - Multiple spaces after blockquote symbol",
817
- "type": "boolean",
818
- "default": true
475
+ "$ref": "#/properties/MD027"
819
476
  },
820
477
  "MD028": {
821
478
  "description": "MD028/no-blanks-blockquote - Blank line inside blockquote",
@@ -823,9 +480,7 @@
823
480
  "default": true
824
481
  },
825
482
  "no-blanks-blockquote": {
826
- "description": "MD028/no-blanks-blockquote - Blank line inside blockquote",
827
- "type": "boolean",
828
- "default": true
483
+ "$ref": "#/properties/MD028"
829
484
  },
830
485
  "MD029": {
831
486
  "description": "MD029/ol-prefix - Ordered list item prefix",
@@ -850,26 +505,7 @@
850
505
  "additionalProperties": false
851
506
  },
852
507
  "ol-prefix": {
853
- "description": "MD029/ol-prefix - Ordered list item prefix",
854
- "type": [
855
- "boolean",
856
- "object"
857
- ],
858
- "default": true,
859
- "properties": {
860
- "style": {
861
- "description": "List style",
862
- "type": "string",
863
- "enum": [
864
- "one",
865
- "ordered",
866
- "one_or_ordered",
867
- "zero"
868
- ],
869
- "default": "one_or_ordered"
870
- }
871
- },
872
- "additionalProperties": false
508
+ "$ref": "#/properties/MD029"
873
509
  },
874
510
  "MD030": {
875
511
  "description": "MD030/list-marker-space - Spaces after list markers",
@@ -882,56 +518,32 @@
882
518
  "ul_single": {
883
519
  "description": "Spaces for single-line unordered list items",
884
520
  "type": "integer",
521
+ "minimum": 1,
885
522
  "default": 1
886
523
  },
887
524
  "ol_single": {
888
525
  "description": "Spaces for single-line ordered list items",
889
526
  "type": "integer",
527
+ "minimum": 1,
890
528
  "default": 1
891
529
  },
892
530
  "ul_multi": {
893
531
  "description": "Spaces for multi-line unordered list items",
894
532
  "type": "integer",
533
+ "minimum": 1,
895
534
  "default": 1
896
535
  },
897
536
  "ol_multi": {
898
537
  "description": "Spaces for multi-line ordered list items",
899
538
  "type": "integer",
539
+ "minimum": 1,
900
540
  "default": 1
901
541
  }
902
542
  },
903
543
  "additionalProperties": false
904
544
  },
905
545
  "list-marker-space": {
906
- "description": "MD030/list-marker-space - Spaces after list markers",
907
- "type": [
908
- "boolean",
909
- "object"
910
- ],
911
- "default": true,
912
- "properties": {
913
- "ul_single": {
914
- "description": "Spaces for single-line unordered list items",
915
- "type": "integer",
916
- "default": 1
917
- },
918
- "ol_single": {
919
- "description": "Spaces for single-line ordered list items",
920
- "type": "integer",
921
- "default": 1
922
- },
923
- "ul_multi": {
924
- "description": "Spaces for multi-line unordered list items",
925
- "type": "integer",
926
- "default": 1
927
- },
928
- "ol_multi": {
929
- "description": "Spaces for multi-line ordered list items",
930
- "type": "integer",
931
- "default": 1
932
- }
933
- },
934
- "additionalProperties": false
546
+ "$ref": "#/properties/MD030"
935
547
  },
936
548
  "MD031": {
937
549
  "description": "MD031/blanks-around-fences - Fenced code blocks should be surrounded by blank lines",
@@ -950,20 +562,7 @@
950
562
  "additionalProperties": false
951
563
  },
952
564
  "blanks-around-fences": {
953
- "description": "MD031/blanks-around-fences - Fenced code blocks should be surrounded by blank lines",
954
- "type": [
955
- "boolean",
956
- "object"
957
- ],
958
- "default": true,
959
- "properties": {
960
- "list_items": {
961
- "description": "Include list items",
962
- "type": "boolean",
963
- "default": true
964
- }
965
- },
966
- "additionalProperties": false
565
+ "$ref": "#/properties/MD031"
967
566
  },
968
567
  "MD032": {
969
568
  "description": "MD032/blanks-around-lists - Lists should be surrounded by blank lines",
@@ -971,9 +570,7 @@
971
570
  "default": true
972
571
  },
973
572
  "blanks-around-lists": {
974
- "description": "MD032/blanks-around-lists - Lists should be surrounded by blank lines",
975
- "type": "boolean",
976
- "default": true
573
+ "$ref": "#/properties/MD032"
977
574
  },
978
575
  "MD033": {
979
576
  "description": "MD033/no-inline-html - Inline HTML",
@@ -995,23 +592,7 @@
995
592
  "additionalProperties": false
996
593
  },
997
594
  "no-inline-html": {
998
- "description": "MD033/no-inline-html - Inline HTML",
999
- "type": [
1000
- "boolean",
1001
- "object"
1002
- ],
1003
- "default": true,
1004
- "properties": {
1005
- "allowed_elements": {
1006
- "description": "Allowed elements",
1007
- "type": "array",
1008
- "items": {
1009
- "type": "string"
1010
- },
1011
- "default": []
1012
- }
1013
- },
1014
- "additionalProperties": false
595
+ "$ref": "#/properties/MD033"
1015
596
  },
1016
597
  "MD034": {
1017
598
  "description": "MD034/no-bare-urls - Bare URL used",
@@ -1019,9 +600,7 @@
1019
600
  "default": true
1020
601
  },
1021
602
  "no-bare-urls": {
1022
- "description": "MD034/no-bare-urls - Bare URL used",
1023
- "type": "boolean",
1024
- "default": true
603
+ "$ref": "#/properties/MD034"
1025
604
  },
1026
605
  "MD035": {
1027
606
  "description": "MD035/hr-style - Horizontal rule style",
@@ -1040,20 +619,7 @@
1040
619
  "additionalProperties": false
1041
620
  },
1042
621
  "hr-style": {
1043
- "description": "MD035/hr-style - Horizontal rule style",
1044
- "type": [
1045
- "boolean",
1046
- "object"
1047
- ],
1048
- "default": true,
1049
- "properties": {
1050
- "style": {
1051
- "description": "Horizontal rule style",
1052
- "type": "string",
1053
- "default": "consistent"
1054
- }
1055
- },
1056
- "additionalProperties": false
622
+ "$ref": "#/properties/MD035"
1057
623
  },
1058
624
  "MD036": {
1059
625
  "description": "MD036/no-emphasis-as-heading/no-emphasis-as-header - Emphasis used instead of a heading",
@@ -1072,36 +638,10 @@
1072
638
  "additionalProperties": false
1073
639
  },
1074
640
  "no-emphasis-as-heading": {
1075
- "description": "MD036/no-emphasis-as-heading/no-emphasis-as-header - Emphasis used instead of a heading",
1076
- "type": [
1077
- "boolean",
1078
- "object"
1079
- ],
1080
- "default": true,
1081
- "properties": {
1082
- "punctuation": {
1083
- "description": "Punctuation characters",
1084
- "type": "string",
1085
- "default": ".,;:!?。,;:!?"
1086
- }
1087
- },
1088
- "additionalProperties": false
641
+ "$ref": "#/properties/MD036"
1089
642
  },
1090
643
  "no-emphasis-as-header": {
1091
- "description": "MD036/no-emphasis-as-heading/no-emphasis-as-header - Emphasis used instead of a heading",
1092
- "type": [
1093
- "boolean",
1094
- "object"
1095
- ],
1096
- "default": true,
1097
- "properties": {
1098
- "punctuation": {
1099
- "description": "Punctuation characters",
1100
- "type": "string",
1101
- "default": ".,;:!?。,;:!?"
1102
- }
1103
- },
1104
- "additionalProperties": false
644
+ "$ref": "#/properties/MD036"
1105
645
  },
1106
646
  "MD037": {
1107
647
  "description": "MD037/no-space-in-emphasis - Spaces inside emphasis markers",
@@ -1109,9 +649,7 @@
1109
649
  "default": true
1110
650
  },
1111
651
  "no-space-in-emphasis": {
1112
- "description": "MD037/no-space-in-emphasis - Spaces inside emphasis markers",
1113
- "type": "boolean",
1114
- "default": true
652
+ "$ref": "#/properties/MD037"
1115
653
  },
1116
654
  "MD038": {
1117
655
  "description": "MD038/no-space-in-code - Spaces inside code span elements",
@@ -1119,9 +657,7 @@
1119
657
  "default": true
1120
658
  },
1121
659
  "no-space-in-code": {
1122
- "description": "MD038/no-space-in-code - Spaces inside code span elements",
1123
- "type": "boolean",
1124
- "default": true
660
+ "$ref": "#/properties/MD038"
1125
661
  },
1126
662
  "MD039": {
1127
663
  "description": "MD039/no-space-in-links - Spaces inside link text",
@@ -1129,9 +665,7 @@
1129
665
  "default": true
1130
666
  },
1131
667
  "no-space-in-links": {
1132
- "description": "MD039/no-space-in-links - Spaces inside link text",
1133
- "type": "boolean",
1134
- "default": true
668
+ "$ref": "#/properties/MD039"
1135
669
  },
1136
670
  "MD040": {
1137
671
  "description": "MD040/fenced-code-language - Fenced code blocks should have a language specified",
@@ -1139,9 +673,7 @@
1139
673
  "default": true
1140
674
  },
1141
675
  "fenced-code-language": {
1142
- "description": "MD040/fenced-code-language - Fenced code blocks should have a language specified",
1143
- "type": "boolean",
1144
- "default": true
676
+ "$ref": "#/properties/MD040"
1145
677
  },
1146
678
  "MD041": {
1147
679
  "description": "MD041/first-line-heading/first-line-h1 - First line in a file should be a top-level heading",
@@ -1154,6 +686,8 @@
1154
686
  "level": {
1155
687
  "description": "Heading level",
1156
688
  "type": "integer",
689
+ "minimum": 1,
690
+ "maximum": 6,
1157
691
  "default": 1
1158
692
  },
1159
693
  "front_matter_title": {
@@ -1165,46 +699,10 @@
1165
699
  "additionalProperties": false
1166
700
  },
1167
701
  "first-line-heading": {
1168
- "description": "MD041/first-line-heading/first-line-h1 - First line in a file should be a top-level heading",
1169
- "type": [
1170
- "boolean",
1171
- "object"
1172
- ],
1173
- "default": true,
1174
- "properties": {
1175
- "level": {
1176
- "description": "Heading level",
1177
- "type": "integer",
1178
- "default": 1
1179
- },
1180
- "front_matter_title": {
1181
- "description": "RegExp for matching title in front matter",
1182
- "type": "string",
1183
- "default": "^\\s*title\\s*[:=]"
1184
- }
1185
- },
1186
- "additionalProperties": false
702
+ "$ref": "#/properties/MD041"
1187
703
  },
1188
704
  "first-line-h1": {
1189
- "description": "MD041/first-line-heading/first-line-h1 - First line in a file should be a top-level heading",
1190
- "type": [
1191
- "boolean",
1192
- "object"
1193
- ],
1194
- "default": true,
1195
- "properties": {
1196
- "level": {
1197
- "description": "Heading level",
1198
- "type": "integer",
1199
- "default": 1
1200
- },
1201
- "front_matter_title": {
1202
- "description": "RegExp for matching title in front matter",
1203
- "type": "string",
1204
- "default": "^\\s*title\\s*[:=]"
1205
- }
1206
- },
1207
- "additionalProperties": false
705
+ "$ref": "#/properties/MD041"
1208
706
  },
1209
707
  "MD042": {
1210
708
  "description": "MD042/no-empty-links - No empty links",
@@ -1212,9 +710,7 @@
1212
710
  "default": true
1213
711
  },
1214
712
  "no-empty-links": {
1215
- "description": "MD042/no-empty-links - No empty links",
1216
- "type": "boolean",
1217
- "default": true
713
+ "$ref": "#/properties/MD042"
1218
714
  },
1219
715
  "MD043": {
1220
716
  "description": "MD043/required-headings/required-headers - Required heading structure",
@@ -1228,7 +724,8 @@
1228
724
  "description": "List of headings",
1229
725
  "type": "array",
1230
726
  "items": {
1231
- "type": "string"
727
+ "type": "string",
728
+ "pattern": "^(\\*|\\+|#{1,6} .*)$"
1232
729
  },
1233
730
  "default": []
1234
731
  },
@@ -1236,7 +733,8 @@
1236
733
  "description": "List of headings",
1237
734
  "type": "array",
1238
735
  "items": {
1239
- "type": "string"
736
+ "type": "string",
737
+ "pattern": "^(\\*|\\+|#{1,6} .*)$"
1240
738
  },
1241
739
  "default": []
1242
740
  }
@@ -1244,58 +742,10 @@
1244
742
  "additionalProperties": false
1245
743
  },
1246
744
  "required-headings": {
1247
- "description": "MD043/required-headings/required-headers - Required heading structure",
1248
- "type": [
1249
- "boolean",
1250
- "object"
1251
- ],
1252
- "default": true,
1253
- "properties": {
1254
- "headings": {
1255
- "description": "List of headings",
1256
- "type": "array",
1257
- "items": {
1258
- "type": "string"
1259
- },
1260
- "default": []
1261
- },
1262
- "headers": {
1263
- "description": "List of headings",
1264
- "type": "array",
1265
- "items": {
1266
- "type": "string"
1267
- },
1268
- "default": []
1269
- }
1270
- },
1271
- "additionalProperties": false
745
+ "$ref": "#/properties/MD043"
1272
746
  },
1273
747
  "required-headers": {
1274
- "description": "MD043/required-headings/required-headers - Required heading structure",
1275
- "type": [
1276
- "boolean",
1277
- "object"
1278
- ],
1279
- "default": true,
1280
- "properties": {
1281
- "headings": {
1282
- "description": "List of headings",
1283
- "type": "array",
1284
- "items": {
1285
- "type": "string"
1286
- },
1287
- "default": []
1288
- },
1289
- "headers": {
1290
- "description": "List of headings",
1291
- "type": "array",
1292
- "items": {
1293
- "type": "string"
1294
- },
1295
- "default": []
1296
- }
1297
- },
1298
- "additionalProperties": false
748
+ "$ref": "#/properties/MD043"
1299
749
  },
1300
750
  "MD044": {
1301
751
  "description": "MD044/proper-names - Proper names should have the correct capitalization",
@@ -1317,43 +767,25 @@
1317
767
  "description": "Include code blocks",
1318
768
  "type": "boolean",
1319
769
  "default": true
1320
- }
1321
- },
1322
- "additionalProperties": false
1323
- },
1324
- "proper-names": {
1325
- "description": "MD044/proper-names - Proper names should have the correct capitalization",
1326
- "type": [
1327
- "boolean",
1328
- "object"
1329
- ],
1330
- "default": true,
1331
- "properties": {
1332
- "names": {
1333
- "description": "List of proper names",
1334
- "type": "array",
1335
- "items": {
1336
- "type": "string"
1337
- },
1338
- "default": []
1339
770
  },
1340
- "code_blocks": {
1341
- "description": "Include code blocks",
771
+ "html_elements": {
772
+ "description": "Include HTML elements",
1342
773
  "type": "boolean",
1343
774
  "default": true
1344
775
  }
1345
776
  },
1346
777
  "additionalProperties": false
1347
778
  },
779
+ "proper-names": {
780
+ "$ref": "#/properties/MD044"
781
+ },
1348
782
  "MD045": {
1349
783
  "description": "MD045/no-alt-text - Images should have alternate text (alt text)",
1350
784
  "type": "boolean",
1351
785
  "default": true
1352
786
  },
1353
787
  "no-alt-text": {
1354
- "description": "MD045/no-alt-text - Images should have alternate text (alt text)",
1355
- "type": "boolean",
1356
- "default": true
788
+ "$ref": "#/properties/MD045"
1357
789
  },
1358
790
  "MD046": {
1359
791
  "description": "MD046/code-block-style - Code block style",
@@ -1377,25 +809,7 @@
1377
809
  "additionalProperties": false
1378
810
  },
1379
811
  "code-block-style": {
1380
- "description": "MD046/code-block-style - Code block style",
1381
- "type": [
1382
- "boolean",
1383
- "object"
1384
- ],
1385
- "default": true,
1386
- "properties": {
1387
- "style": {
1388
- "description": "Block style",
1389
- "type": "string",
1390
- "enum": [
1391
- "consistent",
1392
- "fenced",
1393
- "indented"
1394
- ],
1395
- "default": "consistent"
1396
- }
1397
- },
1398
- "additionalProperties": false
812
+ "$ref": "#/properties/MD046"
1399
813
  },
1400
814
  "MD047": {
1401
815
  "description": "MD047/single-trailing-newline - Files should end with a single newline character",
@@ -1403,9 +817,7 @@
1403
817
  "default": true
1404
818
  },
1405
819
  "single-trailing-newline": {
1406
- "description": "MD047/single-trailing-newline - Files should end with a single newline character",
1407
- "type": "boolean",
1408
- "default": true
820
+ "$ref": "#/properties/MD047"
1409
821
  },
1410
822
  "MD048": {
1411
823
  "description": "MD048/code-fence-style - Code fence style",
@@ -1429,25 +841,7 @@
1429
841
  "additionalProperties": false
1430
842
  },
1431
843
  "code-fence-style": {
1432
- "description": "MD048/code-fence-style - Code fence style",
1433
- "type": [
1434
- "boolean",
1435
- "object"
1436
- ],
1437
- "default": true,
1438
- "properties": {
1439
- "style": {
1440
- "description": "Code fence style",
1441
- "type": "string",
1442
- "enum": [
1443
- "consistent",
1444
- "backtick",
1445
- "tilde"
1446
- ],
1447
- "default": "consistent"
1448
- }
1449
- },
1450
- "additionalProperties": false
844
+ "$ref": "#/properties/MD048"
1451
845
  },
1452
846
  "MD049": {
1453
847
  "description": "MD049/emphasis-style - Emphasis style should be consistent",
@@ -1471,25 +865,7 @@
1471
865
  "additionalProperties": false
1472
866
  },
1473
867
  "emphasis-style": {
1474
- "description": "MD049/emphasis-style - Emphasis style should be consistent",
1475
- "type": [
1476
- "boolean",
1477
- "object"
1478
- ],
1479
- "default": true,
1480
- "properties": {
1481
- "style": {
1482
- "description": "Emphasis style should be consistent",
1483
- "type": "string",
1484
- "enum": [
1485
- "consistent",
1486
- "asterisk",
1487
- "underscore"
1488
- ],
1489
- "default": "consistent"
1490
- }
1491
- },
1492
- "additionalProperties": false
868
+ "$ref": "#/properties/MD049"
1493
869
  },
1494
870
  "MD050": {
1495
871
  "description": "MD050/strong-style - Strong style should be consistent",
@@ -1513,25 +889,31 @@
1513
889
  "additionalProperties": false
1514
890
  },
1515
891
  "strong-style": {
1516
- "description": "MD050/strong-style - Strong style should be consistent",
1517
- "type": [
1518
- "boolean",
1519
- "object"
1520
- ],
1521
- "default": true,
1522
- "properties": {
1523
- "style": {
1524
- "description": "Strong style should be consistent",
1525
- "type": "string",
1526
- "enum": [
1527
- "consistent",
1528
- "asterisk",
1529
- "underscore"
1530
- ],
1531
- "default": "consistent"
1532
- }
1533
- },
1534
- "additionalProperties": false
892
+ "$ref": "#/properties/MD050"
893
+ },
894
+ "MD051": {
895
+ "description": "MD051/link-fragments - Link fragments should be valid",
896
+ "type": "boolean",
897
+ "default": true
898
+ },
899
+ "link-fragments": {
900
+ "$ref": "#/properties/MD051"
901
+ },
902
+ "MD052": {
903
+ "description": "MD052/reference-links-images - Reference links and images should use a label that is defined",
904
+ "type": "boolean",
905
+ "default": true
906
+ },
907
+ "reference-links-images": {
908
+ "$ref": "#/properties/MD052"
909
+ },
910
+ "MD053": {
911
+ "description": "MD053/link-image-reference-definitions - Link and image reference definitions should be needed",
912
+ "type": "boolean",
913
+ "default": true
914
+ },
915
+ "link-image-reference-definitions": {
916
+ "$ref": "#/properties/MD053"
1535
917
  },
1536
918
  "headings": {
1537
919
  "description": "headings - MD001, MD002, MD003, MD018, MD019, MD020, MD021, MD022, MD023, MD024, MD025, MD026, MD036, MD041, MD043",
@@ -1569,7 +951,7 @@
1569
951
  "default": true
1570
952
  },
1571
953
  "links": {
1572
- "description": "links - MD011, MD034, MD039, MD042",
954
+ "description": "links - MD011, MD034, MD039, MD042, MD051, MD052, MD053",
1573
955
  "type": "boolean",
1574
956
  "default": true
1575
957
  },
@@ -1649,7 +1031,7 @@
1649
1031
  "default": true
1650
1032
  },
1651
1033
  "images": {
1652
- "description": "images - MD045",
1034
+ "description": "images - MD045, MD052, MD053",
1653
1035
  "type": "boolean",
1654
1036
  "default": true
1655
1037
  }