# Appendix B: An alternate spec for HTML blocks {-} (The following spec departs less from original markdown than the one described above, but is also less flexible.) An [HTML block](#html-block) begins with an [open tag](#open-tag), [HTML comment](#html-comment), [processing instruction](#processing-instruction), [declaration](#declaration), or [CDATA section](#cdata-section). This opening element may optionally be preceded by 1-3 spaces, and must not be followed on a line by anything other than white space. If the opening tag is self-closing, or if it is an [HTML comment](#html-comment), [processing instruction](#processing-instruction), [declaration](#declaration), or [CDATA section](#cdata-section), then the [HTML block](#html-block) contains just that tag. If it is an [open tag](#open-tag), then the [HTML block](#html-block) continues until a matching closing tag is found, or until the end of the document. Note that the matching closing tag is not necessarily the first closing tag of the same type that is encountered, since that tag may close a later open tag of the same type. Open and closing tags must be balanced. The contents of the HTML block are interpreted as raw HTML, and will not be escaped in HTML output. Some simple examples: .
hi |
hi |
okay.
. .fooö
fooö
<!-- foo -->
.
The opening tag must be on a line (or lines) by itself:
.
foo |
bar
. The opening tag need not be an HTML block tag or even an HTML tag: . foo . foo . .bar