Function: getBlockTypeCounts()
function getBlockTypeCounts(block, opt_stripFollowing?): object;
Defined in: packages/blockly/core/common.ts:240
Get a map of all the block's descendants mapping their type to the number of children with that type.
Parameters
| Parameter | Type | Description |
|---|---|---|
block | Block | The block to map. |
opt_stripFollowing? | boolean | Optionally ignore all following statements (blocks that are not inside a value or statement input of the block). |
Returns
object
Map of types to type counts for descendants of the bock.