blockly > Toolbox > getToolboxItemById

Toolbox.getToolboxItemById() method

Gets the toolbox item with the given ID.

Signature:

getToolboxItemById(id: string): IToolboxItem | null;

Parameters

Parameter Type Description
id string The ID of the toolbox item.

Returns:

IToolboxItem | null

The toolbox item with the given ID, or null if no item exists.