Markdown internal metadata Re: Markdown validity
John MacFarlane
jgm at berkeley.edu
Sun Jul 13 02:21:16 EDT 2014
+++ Sean Leonard [Jul 12 14 17:26 ]:
>I think I can move on to my next question:
>
>It seems that all Markdown content is expected to appear inside of a
>block-level element in HTML parlance; i.e., inside <body> or one of
>its block-level descendants (<div>, <p>, <td>, <form>, <h1>...<h6>,
>etc.).
>
>I tried to do some <head> stuff, as in:
>http://johnmacfarlane.net/babelmark2/?text=%3Chead%3E%3Ctitle%3EHello+World%3C%2Ftitle%3E%3Cmeta+name%3D%22author%22+content%3D%22Alice%22%3E%3C%2Fhead%3E%0A%0AI+am+some+text.%0A%3Cdiv%3Eand+i+am+inside+*myself*%3C%2Fdiv%3E%0A%0AThe+end.
>
>And not surprisingly, the results are all over the place. Clearly this
>is not an effective way to communicate HTML metadata, since Markdown
>is designed to process HTML block-level content.
>
>Therefore, *when it matters*, what are strategies that Markdown users
>currently use to manage HTML metadata such as those metadata items
>defined in <http://www.w3.org/TR/html5/document-metadata.html> and
><http://www.w3.org/TR/html401/struct/global.html#h-7.4>?
>
>I am interested in items such as:
>title
>meta name info (author, generator, description, keywords)
>link rel (stylesheet, icon, etc.)
>language (either http-equiv content-language, or <html lang="XX">)
>date [not part of HTML, but see pandoc_title_block]
>?
There is no standardization here. However, pandoc has moved on to a
more flexible system allowing structured YAML metadata, which may be
placed anywhere in the document.
http://johnmacfarlane.net/pandoc/README.html#yaml-metadata-block
More information about the Markdown-Discuss
mailing list