Stay organized with collections
Save and categorize content based on your preferences.
blockly > BlockSvg > saveConnections
BlockSvg.saveConnections property
An optional method which saves a record of blocks connected to this block so they can be later restored after this block is recoomposed (reconfigured). Typically records the connected blocks on properties on blocks in the mutator flyout, so that rearranging those component blocks will automatically rearrange the corresponding connected blocks on this block after this block is recomposed.
To keep the saved connection information up-to-date, MutatorIcon arranges for an event listener to call this method any time the mutator flyout is open and a change occurs on this block's workspace.
Signature:
saveConnections?: (rootBlock: BlockSvg) => void;
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-05-16 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-16 UTC."],[],["The `saveConnections` property within the `BlockSvg` class is a function that accepts a `BlockSvg` object as its parameter (p1). This function's purpose is to handle the saving of connections related to the input `BlockSvg` instance. It is defined as an optional property using `?:`, so it might not be defined in every instance.\n"]]