Function: shadowBlockConversionChangeListener()
function shadowBlockConversionChangeListener(event): void;
Defined in: plugins/shadow-block-converter/src/shadow_block_converter.ts:319
Add this function to your workspace as a change listener to automatically convert shadow blocks to real blocks whenever the user edits a field on the block, like this:
workspace.addChangeListener(shadowBlockConversionChangeListener);
Ideally the Blockly.Field.prototype.setValue method should handle this logic, but for the purposes of this plugin it can be a workspace change listener.
Parameters
| Parameter | Type | Description |
|---|---|---|
event | Abstract | An event broadcast by the workspace. |
Returns
void