render
Returns HTML raw texts
render(children, [...args])​
added in 1.3.0children
- <JSX.Element>. Input string, acceptsTemplateStringArray
instead of string.args
- <Object> reply context object. Note:render
already uses{parse_mode: 'HTML'}
. Do not overwrite this property
returns​
Array of raw text without text modifiers and array of modifiers.
Example​
const formatteed = render(
<Fragment>
some <Bold>bold</Bold> text
</Fragment>
);
formatted[0]; // some <b>bold</b> text
formatted[1]; // { parse_mode: 'HTML'}