ScribbleSVG

@scribblesvg/react-utils

React components for diagram display and editing

@scribblesvg/react-utils provides React surfaces over @scribblesvg/core:

Install

pnpm add @scribblesvg/react-utils @scribblesvg/core

Peer dependencies: React 18 or 19.

Subpath exports

ImportContents
@scribblesvg/react-utils/editor.cssBuilt-in styles for DiagramCanvas
@scribblesvg/react-utils/rendererDiagramRenderer, color presets and helpers
@scribblesvg/react-utils/editorDiagramCanvas, toolbar, hooks, hit-testing
@scribblesvg/react-utils/iconsDiagramIcon, resolveDiagramIcon, catalog helpers
@scribblesvg/react-utils/colorsDiagramColors, resolveDiagramColors, presets

The editor entry also exports lower-level pieces if you want to build your own UI: useCanvasReducer, interaction hooks, coordinate utils, hit testing.

License

MIT

On this page