Post texts and some profile fields are returned as HTML. Here are the HTML tags that Smithereen may include in these fields and expects your app to support, and that it accepts in methods which take formatted text with text_format set to html:

  • <a> for both regular links and user mentions. User mentions have a mention class and an extra data-user-id attribute specifying the user ID.
  • Text style: <b>, <i>, <u>, <s>, <code>, <sub>, <sup>
  • Quotes: <blockquote>
  • Paragraphs: <p>
  • Code blocks: <pre>
  • Line breaks: <br>

Additionally, on input, @mentions and URLs are parsed into links automatically.

Markdown support

With text_format set to markdown, the following features are supported:

  • *italic* or _italic_
  • **bold** or __bold__
  • ++underlined++
  • ~strikethrough~ or ~~strikethrough~~
  • `inline monospace`
  • [links](https://...)
  • > quotes
  • ``` code blocks ```

Additionally, on input, @mentions and URLs are parsed into links automatically.

Plain text

With text_format set to plain, no formatting syntax is used, but @mentions and URLs are still parsed.