mirror of
https://github.com/showdownjs/showdown.git
synced 2024-03-22 13:30:55 +08:00
35 lines
444 B
Markdown
35 lines
444 B
Markdown
|
# Spec Compliance
|
||
|
|
||
|
## Commonmark
|
||
|
|
||
|
Compliance percentage:
|
||
|
|
||
|
### How to enable commonmark flavor
|
||
|
|
||
|
Enable Commonmark flavor
|
||
|
|
||
|
```
|
||
|
let converter = new showdown.Converter();
|
||
|
converter.setFlavor('commonmark');
|
||
|
```
|
||
|
|
||
|
### Known differences:
|
||
|
|
||
|
#### ATX Headings
|
||
|
|
||
|
- Showdown doesn't support empty headings
|
||
|
|
||
|
Input:
|
||
|
```md
|
||
|
#
|
||
|
```
|
||
|
|
||
|
Showdown Output:
|
||
|
```html
|
||
|
<p>#</p>
|
||
|
```
|
||
|
|
||
|
Commonmark output:
|
||
|
```
|
||
|
<h1></h1>
|
||
|
```
|