mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-23 01:09:42 +02:00
#2017 Fix for clearing diagram data (helpful for live editor)
This commit is contained in:
@@ -323,6 +323,7 @@ const elementString = str => {
|
|||||||
|
|
||||||
export const draw = (text, id) => {
|
export const draw = (text, id) => {
|
||||||
parser.yy = requirementDb;
|
parser.yy = requirementDb;
|
||||||
|
parser.yy.clear();
|
||||||
parser.parse(text);
|
parser.parse(text);
|
||||||
|
|
||||||
const svg = select(`[id='${id}']`);
|
const svg = select(`[id='${id}']`);
|
||||||
|
Reference in New Issue
Block a user