SVG

A reference to an external SVG file by URL (e.g. starts with cuttle-svg://).

To load an SVG and render it, pass an SVG to getSVGFromURL which returns an SVGRenderer.

const svgRenderer = getSVGFromURL(svg);
if (!svgRenderer) return [];
return svgRenderer.render();

Constructors

SVG(svg)SVG
svg
(string | SVG)

Properties

.urlstring

The URL of the SVG file (e.g. starts with cuttle-svg://).

Methods

.equals(svg)boolean

Two SVGs are equal when they reference the same URL.

svg