Stay organized with collections
Save and categorize content based on your preferences.
blockly > Options > GridOptions > snap
Options.GridOptions.snap property
Signature:
snap: boolean;
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 2024-09-18 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 2024-09-18 UTC."],[[["\u003cp\u003e\u003ccode\u003esnap\u003c/code\u003e: Determines if blocks should snap to the grid, enhancing user experience by ensuring consistent placement and alignment of blocks within the workspace.\u003c/p\u003e\n"],["\u003cp\u003eThis property, when set to \u003ccode\u003etrue\u003c/code\u003e, dictates that blocks will automatically align themselves with the grid lines during dragging and placement, promoting an orderly and structured workspace layout.\u003c/p\u003e\n"]]],[],null,["[blockly](./blockly.md) \\\u003e [Options](./blockly.options_namespace.md) \\\u003e [GridOptions](./blockly.options_namespace.gridoptions_interface.md) \\\u003e [snap](./blockly.options_namespace.gridoptions_interface.snap_propertysignature.md)\n\nOptions.GridOptions.snap property\n---------------------------------\n\n**Signature:** \n\n snap: boolean;"]]