iurysza / module-graph

A Gradle Plugin for visualizing your project's structure, powered by mermaidjs
https://plugins.gradle.org/plugin/dev.iurysouza.modulegraph
MIT License
346 stars 13 forks source link

`maxTextSize` config example #48

Closed avladgh closed 4 months ago

avladgh commented 6 months ago

⚠️ Is your feature request related to a problem? Please describe

Getting "Maximum text size in diagram exceeded" error in large project, and I can't figure out how to change the maxTextSize property in config.

💡 Describe the solution you'd like

An example how to change 'maxTextSize'

🤚 Do you want to develop this feature yourself?

iurysza commented 6 months ago

Hey, we unfortunately can't get around that limit when embedding the diagram in markdown. This maxTextSize option only works with MermaidJS using HTML and JS.

I suggest using one of our filtering properties or generating multiple graphs with the rootModulesRegex property. These regex patterns also pickup the parent folder name. So, you could generate a graph covering all modules in a features folder, for example.

Now, if you really need everything in one graph, you can try manually changing the defaultRenderer:

%%{
  init: {
      "flowchart": { "defaultRenderer": "elk"}
  }
}%%

Let me know if that works out. Cheers.