diff --git a/cypress/platform/render-after-error.html b/cypress/platform/render-after-error.html index 059f79345..96dcd3f8b 100644 --- a/cypress/platform/render-after-error.html +++ b/cypress/platform/render-after-error.html @@ -17,10 +17,10 @@ (async () => { try { console.log('rendering'); - await mermaid.mermaidAPI.render('graphDiv', `>`); + await mermaid.mermaidAPI.renderAsync('graphDiv', `>`); } catch (e) {} - await mermaid.mermaidAPI.render('graphDiv', `graph LR\n a --> b`, (html) => { + await mermaid.mermaidAPI.renderAsync('graphDiv', `graph LR\n a --> b`, (html) => { document.getElementById('graph').innerHTML = html; }); })(); diff --git a/cypress/platform/rerender.html b/cypress/platform/rerender.html index 61c6891f7..0d7588ef5 100644 --- a/cypress/platform/rerender.html +++ b/cypress/platform/rerender.html @@ -19,7 +19,7 @@ function rerender(text) { const graphText = `graph TD A[${text}] -->|Get money| B(Go shopping)`; - mermaid.mermaidAPI.render('id', graphText).then((svg) => { + mermaid.mermaidAPI.renderAsync('id', graphText).then((svg) => { console.log('\x1b[35m%s\x1b[0m', '>> graph', svg); document.getElementById('graph').innerHTML = svg; });