I googled a bit, and found that CSS can not hide custom characters by itself, it can only operate on some element. It can add content to elements, but it can’t target characters/text within elements.
With regards to css which hides #
, and the possibility to hide {{}}
I made a little example, and viewed the DOM elements related to this text. See image below:
This might not be very easy to understand, but I’ve highlighted a row in the DOM elements in the right part of the image, and it highlights the corresponding text in the left part. The row I’ve selected corresponds to the element containing the ##
part. When markdown parses this text, the header characters translates into its own element.
On the next line (in the right part), you can see the rest of the header (including an extra {{}}
text), indicating that’s an element by itself.
Finally below that you can see that the entire line Any difference, here {{}}, or not...
is an element on its own. In particular, the {{}}
part is just included within the other text. Thusly any CSS styling will apply to the entire line.
tl;dr My conclusion is therefore that the header characters can be styled/hidden since it’s an element on its own, but the {{}}
is just a part of the text and can not be styled/hidden (separate from the rest of the text).