Skip to content

This plugin provides a utility method that converts D2 syntax into a scene graph for the canvas:

ts
import { parseD2ToSerializedNodes } from '@infinite-canvas-tutorial/d2';

const nodes = await parseD2ToSerializedNodes('x -> y: hello world');
api.runAtNextTick(() => {
    api.updateNodes(nodes);
});

Released under the MIT License.