when code end with space, mermaid.parse return true but mermaid.run throw error #6054
Labels
Status: Triage
Needs to be verified, categorized, etc
Type: Bug / Error
Something isn't working or is incorrect
Description
if code end with space,run
mermaid.parse(code)
return true. But when runmermaid.parse({nodes: [ref.current])
throw error.Steps to reproduce
when run
mermaid.parse(code)
return true. But when runmermaid.parse({nodes: [ref.current])
throw error.when I read the source code of
mermaid.run
, I found that it will trim the space of code. It is the reason of the bug.Screenshots
No response
Code Sample
No response
Setup
Suggested Solutions
No response
Additional Context
No response
The text was updated successfully, but these errors were encountered: