Comments (1)
This is an issue we've identified a while back. But due to the internal implementation of how configs are handled, it's not possible for mermaid to apply a config for a single diagram.
We are making efforts to fix this, but as it'll require some major changes, it's been slow.
In the current situation, adding the mermaidOptions to the render function can't be handled by anything more than doing a mermaid.initialize
call inside the render function, as there is no diagram specific config available.
There's 275 calls to getConfig, which always returns the global config.
All these would have to be modified, while passing down the config/db to each function that calls it.
One potential workaround is to add a function to get a site's config, enabling us to do something like this.
But that's one hacky workraound.
const config = mermaid.getConfig();
mermaid.initialize(someOtherConfig);
await mermaid.render();
mermaid.initialize(config);
from mermaid.
Related Issues (20)
- Tag a commit separate from the line defining the commit in gitGraph HOT 1
- Add support for nested namespaces HOT 2
- The diagram renders only once. HOT 1
- How to put URL in timeline ?
- Bad Gantt Chart Will Cause UI to Hang
- Please add data attributes `data-from-id` and `data-to-id` to `g class='edgeLabel'` svg / make it clickable in flowchart HOT 2
- Parsing error when assigning a hex color value to the last attribute of a linkStyle
- Proyecto grabación de pantalla
- Allow linkStyle background-color attribute to override edgeLabel class background-color HOT 1
- Mermaid Chart - Code Editor Constantly Reduces Upwards HOT 4
- 'Graph' keyword in mindmap diagram breaks if elk renderer set for flowchart
- click/hover to Expand or collapse subgraphs/par
- Flowchart interaction docs fail: o[n] is not a function HOT 2
- UPN - Universal Process Notation
- Flowchart edges not found: Diagram db `getEdges` returining edges which aren't drawn on DOM
- Cannot add behaviors to parent composite states
- Failure to load in Safari 14 since 10.5.0-alpha.1 and a solution
- Actor type in sequence diagram has wrong ordering
- Block diagram: Converting circular structure to JSON
- Automatic text wrapping in block-beta diagram generates error
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mermaid.