<html>
<head>
<meta charset="utf-8">
<style>
body {
background-color: #000000;
margin: 0;
overflow: hidden;
}
</style>
</head>
<body>
<script src="https://unpkg.com/@sdesalas/3d-force-graph@2.0.0/dist/3d-force-graph.min.js"></script>
<script>
const nodes = [
{ id: 1, name: 1 },
{ id: 2, name: 2 },
{ id: 3, name: 3 }
];
const links = [
{source: 1, target: 2, weight: 0},
{source: 2, target: 3, weight: 0},
{source: 3, target: 1, weight: 0}
];
new ForceGraph3D(document.body, {
forceEngine: 'ngraph',
linkOpacityField: 'weight',
graphData: { nodes, links },
nodeRelSize: 5
});
</script>
</body>
</html>