Bug in displaying mermaid flow diagrams

Steps to reproduce

Try to see a graph in read only mode

flowchart TB  
	A --> C  
	A --> D  
	B --> C  
	B --> D

Expected result

A mermaid diagram, so pretty

Actual result

Instead you get this ;(

Environment

  • Operating system: Mac bigsur
  • Debug info: Error parsing Mermaid diagram!

Lexical error on line 1. Unrecognized text.
graph TD; A[Stuff]
-----^


Additional information

I am not sure I understand this bug report at all.
Make sure you are not introducing non breaking white spaces when you copy paste from outside obsidian.

The code doesn’t work inside the webpage either

My description of the problem isn’t the best sorry, I wrote it up while late at night. The graph view doesn’t work at all in reading mode. And when I tried to look up the syntax I should be using on the markdown syntax thing, I saw that it was broken there as well. So the bug I’m trying to point out is those two. Mermaide code doesn’t work for me in reading view. And also the documentation(?) has broken code