SVG
import { SVG } from '@dxos/react-ui-graph';npm install @dxos/react-ui-graph @dxos/graphSVG is the drawing surface for Graph. SVG.Root makes the SVG element
and the context a projector needs, and the other parts add to it. Import the package’s styles,
@dxos/react-ui-graph/styles/graph.css, once in your app.
| Part | What it is |
|---|---|
SVG.Root |
The SVG element, and the context the graph and its projector read |
SVG.Zoom |
The wrapper that lets the user zoom and pan what it holds |
SVG.Graph |
The Graph component |
SVG.Grid |
A grid behind the drawing. axis adds the axes |
SVG.Markers |
Arrowheads and other markers for edges |
SVG.Mesh |
A hexagonal mesh |
SVG.FPS |
The frame rate, for development |