From e62dd255bc27d9a3e2e051698742437769cde95e Mon Sep 17 00:00:00 2001 From: Alois Klink Date: Thu, 27 Oct 2022 17:18:41 +0100 Subject: [PATCH] feat: expose initThrowsErrorsAsync publicly Expose the function `initThrowsErrorsAsync()` publicly as `mermaid.initThrowsErrorsAsync()`. It has the TSDoc `@alpha` and `@deprecated` tags, so people should be warned that it might be modified in Mermaid v10 or earlier. Needed for `mermaid-cli` to handle `lazyLoadedDiagrams`. --- packages/mermaid/src/mermaid.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/mermaid/src/mermaid.ts b/packages/mermaid/src/mermaid.ts index a49e4b700..98111886e 100644 --- a/packages/mermaid/src/mermaid.ts +++ b/packages/mermaid/src/mermaid.ts @@ -513,6 +513,7 @@ const mermaid: { renderAsync: typeof renderAsync; init: typeof init; initThrowsErrors: typeof initThrowsErrors; + initThrowsErrorsAsync: typeof initThrowsErrorsAsync; initialize: typeof initialize; initializeAsync: typeof initializeAsync; contentLoaded: typeof contentLoaded; @@ -527,6 +528,7 @@ const mermaid: { renderAsync, init, initThrowsErrors, + initThrowsErrorsAsync, initialize, initializeAsync, parseError: undefined,