mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-09-20 15:59:51 +02:00
Refactored rendering sequence diagrams
Fixed default config clobbering issues Updated/corrected sequenceDiagram.spec to set the config using mermaidAPI Enabled freeze on mermaidAPI to protect defaultConfig
This commit is contained in:
@@ -6,11 +6,14 @@ export const setConfig = conf => {
|
||||
};
|
||||
export const getConfig = () => config;
|
||||
|
||||
export const reset = conf => {
|
||||
Object.keys(config).forEach(key => delete config[key]);
|
||||
assignWithDepth(config, conf, { clobber: true });
|
||||
};
|
||||
|
||||
const configApi = {
|
||||
setConfig,
|
||||
getConfig
|
||||
// get conf() {
|
||||
// return config;
|
||||
// }
|
||||
getConfig,
|
||||
reset
|
||||
};
|
||||
export default configApi;
|
||||
|
Reference in New Issue
Block a user