Add front_matter_title parameter to MD025/single-title/single-h1 (refs #169).

This commit is contained in:
David Anson 2019-03-16 20:21:57 -07:00
parent 050cbbba82
commit 61d6311a3e
14 changed files with 124 additions and 32 deletions

View file

@ -28,7 +28,7 @@
},
{
"lineNumber": 4,
"ruleNames": [ "MD025", "single-h1" ],
"ruleNames": [ "MD025", "single-title", "single-h1" ],
"ruleDescription": "Multiple top level headings in the same document",
"ruleInformation": "https://github.com/DavidAnson/markdownlint/blob/v0.0.0/doc/Rules.md#md025",
"errorDetail": null,

View file

@ -0,0 +1,7 @@
{
"default": true,
"MD013": false,
"MD025": {
"front_matter_title": "^\\s*alternate="
}
}

View file

@ -0,0 +1,6 @@
---
alternate="Welcome to Jekyll!"
---
# Top level heading {MD025}
Front matter from [Jekyll documentation](https://jekyllrb.com/docs/posts/#a-typical-post).

View file

@ -4,6 +4,6 @@ title: "Welcome to Jekyll!"
date: 2015-11-17 16:16:01 -0600
categories: jekyll update
---
# Top level heading
# Top level heading {MD025}
Front matter from [Jekyll documentation](https://jekyllrb.com/docs/posts/#a-typical-post).

View file

@ -1,4 +1,7 @@
{
"default": true,
"MD025": {
"front_matter_title": ""
},
"MD041": true
}

View file

@ -1,4 +1,7 @@
{
"default": true,
"MD025": {
"front_matter_title": ""
},
"MD041": true
}

View file

@ -9,7 +9,7 @@ tags:
url: https://example.com
excerpt: Hello World! Vestibulum imperdiet adipiscing arcu, quis aliquam dolor condimentum dapibus. Aliquam fermentum leo aliquet quam volutpat et molestie mauris mattis. Suspendisse semper consequat velit in suscipit.
---
# heading1
# heading1 {MD025}
This is just a sample post.