How to format an inline code in Confluence?

后端 未结 15 602
夕颜
夕颜 2020-12-22 17:57

How can I format an inline code in Confluence like this? I mean, not a separate code block, but just inline classname, for example.

15条回答
  •  无人及你
    2020-12-22 18:37

    Surround your inline text with {{ }}.

    Caveats:

    1. You have to hit the spacebar after }}
    2. You can't copy inline preformatted text and maintain it's look. If you do copy it you might not be able to add {{ }} to fix it. Just retype it or paste without formatting (Cmd ⌘+Shift+V on Mac) then add {{ }} and hit space.
    3. If you add the {{ }} to existing text later, it can not be surrounded by other characters, e.g. if you want parenthesis around your preformatted text, you cannot fix (my text) by adding braces ({{my text}}). First add space around your text ( my text ) then add the {{ }}.

提交回复
热议问题