Update MD041/first-line-h1 to ignore leading HTML comments (fixes #37).

This commit is contained in:
David Anson 2017-02-23 22:08:54 -08:00
parent 15b37d51ff
commit acd36d5802
8 changed files with 56 additions and 15 deletions

View file

@ -1037,17 +1037,13 @@ Parameters: level (number; default 1)
This rule is triggered when the first line in the file isn't a top level (h1)
header:
```
This is a file without a header
```
To fix this, add a header to the top of your file:
```
# File with header
This is a file with a top level header
```
Note: The `level` parameter can be used to change the top level (ex: to h2) in
cases where an h1 is added externally.