mirror of
https://github.com/showdownjs/showdown.git
synced 2024-03-22 13:30:55 +08:00
doc: add metadata code example
This commit is contained in:
parent
7bc285edcb
commit
e7294ddccf
@ -368,6 +368,12 @@ var defaultOptions = showdown.getDefaultOptions();
|
|||||||
* **metadata**: (boolean) [default false] Enable support for document metadata (defined at the top of the document
|
* **metadata**: (boolean) [default false] Enable support for document metadata (defined at the top of the document
|
||||||
between `«««` and `»»»` or between `---` and `---`). (since v.1.8.5)
|
between `«««` and `»»»` or between `---` and `---`). (since v.1.8.5)
|
||||||
|
|
||||||
|
```js
|
||||||
|
var conv = new showdown.Converter({metadata: true});
|
||||||
|
var html = conv.makeHtml(someMd);
|
||||||
|
var metadata = conv.getMetadata(); // returns an object with the document metadata
|
||||||
|
```
|
||||||
|
|
||||||
* **splitAdjacentBlockquotes**: (boolean) [default false] Split adjacent blockquote blocks.(since v.1.8.6)
|
* **splitAdjacentBlockquotes**: (boolean) [default false] Split adjacent blockquote blocks.(since v.1.8.6)
|
||||||
|
|
||||||
**NOTE**: Please note that until **version 1.6.0**, all of these options are ***DISABLED*** by default in the cli tool.
|
**NOTE**: Please note that until **version 1.6.0**, all of these options are ***DISABLED*** by default in the cli tool.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user