diff --git a/packages/mermaid/src/config.ts b/packages/mermaid/src/config.ts index 9468a3e46..05788491d 100644 --- a/packages/mermaid/src/config.ts +++ b/packages/mermaid/src/config.ts @@ -30,7 +30,7 @@ export const updateCurrentConfig = (siteCfg: MermaidConfig, _directives: Mermaid if (sumOfDirectives.theme && sumOfDirectives.theme in theme) { const tmpConfigFromInitialize = assignWithDepth({}, configFromInitialize); const themeVariables = assignWithDepth( - tmpConfigFromInitialize.themeVariables || {}, + tmpConfigFromInitialize.themeVariables ?? {}, sumOfDirectives.themeVariables ); if (cfg.theme && cfg.theme in theme) {