I stumbled upon a thread on the openhab forum that had several notes like “NOTE ITS BACKSLASH #, for some unhelpful reason the forum removes the backslash” following MQTT command line examples and thought I would give it a try for myself.
# (Backslash hash)
\# (Backslash hash wrapped in ticks)
\# (Backslash hash with a 4 space indent)
blah blah blah # (Backslash hash, but not at beginning of the line)
So it seems it can be done as part of a code block just not in regular text.
Just for ref, that thread was Is anyone using the Open Energy Monitor (emonPi)
for the use of markdown and the split screen preview.