MD031: Make rule configurable with lines above/after like MD022
MD031 - Fenced code blocks should be surrounded by blank lines notes in the rationale:
Rationale: Aside from aesthetic reasons, some parsers, including kramdown, will not parse fenced code blocks that don't have blank lines before and after them.
However, we use a Markdown parser with Kramdown-style attributes, which for block-level elements are applied on the line immediately after the block. For example, to apply an ID:
```
this is my code block
```
{: #my-code-block}
Because of this, we'd like to be able to configure MD031 with lines_above and lines_below much like you can for MD022, Headings should be surrounded by blank lines. This would allow us to enable the MD031 rule to enforce an empty line above code blocks while still supporting Kramdown-style attributes on code blocks.
This also affects:
MD058/blanks-around-tables
And FYI, kramdown supports these attributes before or after the content:
{: .lead}
Hi
Try it yourself at:
https://kramdown.electricbook.works/