Skip to main content

Home > blockly > Xml > appendDomToWorkspace

Xml.appendDomToWorkspace() function

Decode an XML DOM and create blocks on the workspace. Position the new blocks immediately below prior blocks, aligned by their starting edge.

Signature:

export declare function appendDomToWorkspace(xml: Element, workspace: WorkspaceSvg): string[];

Parameters

ParameterTypeDescription
xmlElementThe XML DOM.
workspaceWorkspaceSvgThe workspace to add to.

Returns:

string[]

An array containing new block IDs.