Skip to content

Replace Image generation with DOT JS-based rendering #101

@jimbethancourt

Description

@jimbethancourt

Sonatype has identified that JGraphX has a known vulnerability:
https://sbom.sonatype.com/report/T1-a4e79c5353879ed9b588-3209d9d507fc3a-1727273211-8e351c4d6ac9418cb8a26ab64b24c8db

To address this, a DOT file should be generated by RefactorFirst and then rendered via a Javascript library call similar to the following:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Graphviz Example</title>
    <script src="https://d3js.org/d3.v5.min.js"></script>
    <script src="https://unpkg.com/d3-graphviz@3.0.5/build/d3-graphviz.min.js"></script>
</head>
<body>
    <div id="graph"></div>
    <script>
        // Fetch the DOT file
        fetch('path/to/your/file.dot')
            .then(response => response.text())
            .then(dot => {
                // Render the graph
                d3.select("#graph")
                    .graphviz()
                    .renderDot(dot);
            });
    </script>
</body>
</html>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions