Skip to content

Interface: Image

graphviz.Image

Example: Passing a web hosted Image to GraphViz:

ts
import { Graphviz } from "@hpcc-js/wasm/graphviz";

const graphviz = await Graphviz.load();
const svg = graphviz.layout('digraph { a[image="https://.../image.png"]; }', "svg", "dot", { 
   images: [{ 
       path: "https://.../image.png", 
           width: "272px", 
           height: "92px" 
   }] 
});
document.getElementById("placeholder").innerHTML = svg;

Properties

path

path: string

Full URL to image

Defined in

graphviz.ts:34


width

width: string

Defined in

graphviz.ts:35


height

height: string

Defined in

graphviz.ts:36

Released under the Apache-2.0 License.