Stay organized with collections Save and categorize content based on your preferences.

blockly > CodeGenerator > valueToCode

CodeGenerator.valueToCode() method

Generate code representing the specified value input.


valueToCode(block: Block, name: string, outerOrder: number): string;


Parameter Type Description
block Block The block containing the input.
name string The name of the input.
outerOrder number The maximum binding strength (minimum order value) of any operators adjacent to "block".



Generated code or '' if no blocks are connected or the specified input does not exist.