blockly > Xml > workspaceToDom

Xml.workspaceToDom() function

Encode a block tree as XML.

Signature:

export declare function workspaceToDom(workspace: Workspace, skipId?: boolean): Element;

Parameters

Parameter Type Description
workspace Workspace The workspace containing blocks.
skipId boolean (Optional) True if the encoder should skip the block IDs. False by default.

Returns:

Element

XML DOM element.