Skip to content
import SnappingControlsViewModel from "@arcgis/core/widgets/support/SnappingControls/SnappingControlsViewModel.js";
Inheritance:
SnappingControlsViewModelAccessor
Since
ArcGIS Maps SDK for JavaScript 4.21

Provides the logic for the SnappingControls widget.

See also

Constructors

Constructor

Constructor
Parameters
ParameterTypeDescriptionRequired
properties
See the properties table for a list of all the properties that may be passed into the constructor.

Properties

Any properties can be set, retrieved or listened to. See the Watch for changes topic.

declaredClass

readonlyinherited Property
Type
string
Inherited from: Accessor

The name of the class. The declared class name is formatted as esri.folder.className.

snappingOptions

autocast Property
Type
SnappingOptions

The SnappingOptions for sketching. It supports self and feature snapping.

state

readonly Property
Type
SnappingControlsViewModelState

The current state of the view model.

Default value
"disabled"

view

Property
Type
MapViewOrSceneView | null | undefined

The view associated with the SnappingControls widget instance.

Type definitions

SnappingControlsViewModelState

Type definition
Type
"ready" | "disabled"