Markdown utility - carbon-design-system/carbon-for-ibm-dotcom-website GitHub Wiki
Utility
The Markdown utility is a light text formatting utility that will convert a
limited set of markdown to valid HTML markup. Each markdown conversion option
can be turned on or off. By default, this utility will use Carbon classes and
strips out extraneous HTML
tags.
Used by (7)
Back links (10)
Content block (2)
- optional
String
of text formatted using the Markdown utility. - See Markdown utility for more
Content group (2)
- optional
String
of text formatted using the Markdown utility. - See Markdown utility for more
- See Markdown utility for more
Content item (2)
- optional
String
of text formatted using the Markdown utility. - See Markdown utility for more
Data model (1)
copy
| Markdown utility
Universal banner (2)
- optional String of text formatted using Markdown utility with a limited
- See Markdown utility for more
String will be input into the utility, where it will search for particular string patterns and convert them to the corresponding valid HTML markup.
type | markup | description | |
---|---|---|---|
1.1 |
italic |
*italic* or _italic_
|
Renders content between a single * or _ as italic. (e.g. <em> text</em> ) |
1.2 |
bold |
**bold** or __bold__
|
Renders content between a double * or _ as bold . (e.g. <strong> text</strong> ) |
1.3 |
paragraph | \n\n |
Renders content before double new line as a paragraph (e.g. <p> ...content...</p> ) |
1.4 |
unordered list |
- list item 1 * list item 2
|
Renders one or more lines starting with - or * as an unordered list. |
1.5 |
ordered list |
1. list item 1 2. list item 2
|
Renders one or more lines starting with a number 1. or * as an ordered list. |
1.6 |
Hyperlink | [text](url) |
Renders content as an inline Carbon link |