@mocanvas/editor · type

ShapeSvgResult

type ShapeSvgResult = string | ReactNode

What an SVG export callback may return: a raw markup string (inserted verbatim, so it must be well-formed and escaped by the util) or a React node the exporter serializes. undefined means "I have nothing to draw", which lets the exporter fall through to its own renderers.

mocanvas is built by Symbio. Free for non-commercial, non-profit and development use; commercial use needs an agreement. Not affiliated with or endorsed by tldraw.