Skip to main content

Home > blockly > ComponentManager > addComponent

ComponentManager.addComponent() method

Adds a component.

Signature:

addComponent(componentInfo: ComponentDatum, opt_allowOverrides?: boolean): void;

Parameters

ParameterTypeDescription
componentInfoComponentDatumThe data for the component to register.
opt_allowOverridesboolean(Optional) True to prevent an error when overriding an already registered item.

Returns:

void