MarkdownAPI
The markdown API provides utilities for creating markdown using js.
Constructors
new MarkdownAPI()
new MarkdownAPI(
apiInstance
):MarkdownAPI
Parameters
Parameter | Type |
---|---|
|
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:22
Methods
create()
create(
markdown
):MarkdownString
Creates a markdown string form a normal string. This does not modify the string. It only wraps it in an object, so that the plugin can recognize and render it as markdown.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
the string to wrap |
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:40
createBlockQuote()
createBlockQuote():
BlockQuoteElement
Creates a new markdown block quote element.
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:111
createBoldText()
createBoldText(
text
):TextElement
Creates a new markdown text element with bold formatting.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:58
createBuilder()
createBuilder():
MarkdownBuilder
Creates a markdown builder.
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:29
createCallout()
createCallout(
title
,type
,args
):CalloutElement
Creates a new markdown callout element.
Parameters
Parameter | Type | Default value | Description |
---|---|---|---|
|
|
|
the title of the callout |
|
|
|
the type of the callout |
|
|
|
the callout args, optional |
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:122
createCode()
createCode(
text
):CodeElement
Creates a new markdown code element.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:85
createCodeBlock()
createCodeBlock(
language
,content
):CodeBlockElement
Creates a new markdown code block element.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
the language of the code block |
|
|
the content of the code block |
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:132
createCursiveText()
createCursiveText(
text
):TextElement
Creates a new markdown text element with cursive formatting.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:67
createHeading()
createHeading(
level
,content
):HeadingElement
Creates a new markdown heading element.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
the level of the heading from 1 to 6 |
|
|
the text of the heading |
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:104
createList()
createList(
ordered
):ListElement
Creates a new markdown list element.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
whether the list should be ordered or not (use 1. or -) |
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:151
createParagraph()
createParagraph(
content
):ParagraphElement
Creates a new markdown paragraph element.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:94
createTable()
createTable(
header
,body
):TableElement
Creates a new markdown table element.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
the header row |
|
|
the table body |
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:142
createText()
createText(
text
):TextElement
Creates a new markdown text element.
Parameters
Parameter | Type | Description |
---|---|---|
|
|
Returns
Defined in
jsEngine/api/MarkdownAPI.ts:49
createUnderlinedText()
createUnderlinedText(
text
):TextElement
Creates a new markdown text element with underline formatting.
Parameters
Parameter | Type | Description |
---|---|---|
|
|