@mocanvas/mocanvas · function

svgResultToMarkup

declare function svgResultToMarkup(value: ShapeSvgResult): string | undefined

Markup for a value returned by toSvg / toBackgroundSvg: a string is used verbatim, a React node is serialized, and React's empty values become undefined so the caller can fall through to the next renderer.

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.