Release notes for 4.19

April 2021

ES modules - production release

The API's ES modules are now ready for production use, they were originally released in beta at version 4.18. These modules make it easier to do local builds of the API when integrating with third party frameworks and build tools. They are available for installation via the NPM package @arcgis/core.

Install the modules by running npm i @arcgis/core. Then, you can use native imports like this:

Use dark colors for code blocksCopy
1
2
import WebMap from "@arcgis/core/WebMap";
import MapView from "@arcgis/core/views/MapView";

The benefits of this approach include:

  • Simplified code
  • Native support in modern browsers
  • Minimal configuration
  • Seamless integration with all modern frameworks and build tools

Visit the Introduction to tooling guide topic to learn more about the new modules and whether you should migrate. There are also sample apps that demonstrate the basic concepts for getting started.

Assets for local builds

NPM installs of @arcgis/core and arcgis-js-api for local builds now use a CDN as the default way to retrieve assets at runtime. The assets include styles, images, web workers, wasm and localization files. The new default setting will make initial installs and configuration much easier, and can still be overridden using config.assetsPath when working with local assets.

Performance improvements

At this release, we improved the performance of point FeatureLayers hosted on ArcGIS Online. The FeatureLayer will now fetch all its features at once from the server. Once loaded, the features won't need to be re-requested from the server, which will make future redraws after panning and zooming much faster. We will continue to add support for other feature services in the next few upcoming releases.

performance

Editing updates

Snapping

Self snapping support added to 2D

Self-snapping is now supported when creating or updating line and polygon features in 2D. This makes it easier to create geometries that have parallel lines and right angles. To enable snapping, set the snappingOptions.enabled property to true in the Sketch or Editor widget. 3D support for self snapping was previously implemented in 4.18, and is now no longer in beta.

Self snapping will snap to perpendicular lines (right angles), parallel lines, an extension of a line, and to a vertex of the feature being edited, as shown in the images below.

Perpendicular linesParallel linesExtension of a lineVertex
perpendicular parallel extension vertex

Feature snapping now supported in 2D and 3D

We also added support for feature snapping in both 2D and 3D. Now, it is possible to snap to existing features from a FeatureLayer, GraphicsLayer, GeoJSONLayer, or CSVLayer currently loaded on the Map. In order to utilize feature snapping, the SnappingOptions.featureSources must be assigned to one or more of the layers on the map.

3d snap to features

Enable snapping in the Sketch widget

The Sketch widget's UI now includes an options menu to toggle snapping on/off. This control toggles the Sketch.snappingOptions.enabled property. By default, snapping is disabled, but it can be enabled either by toggling the switch in the widget's UI, or by holding the Ctrl key while drawing a graphic.

sketch-snapping-ui

Editor widget

Snapping in Editor

The Editor widget now provides the ability to set snapping when creating or updating features. This is all handled programmatically via the API by setting the snappingOptions property. The snappingOptions object contains various properties for configuring sketch snapping. These configurations include enabling/disabling both self and feature snapping. Information on these two forms of snapping is provided in the SnappingOptions documentation. In addition, please refer to this documentation for any known limitations while working with snapping.

Examples showing this functionality are provided in the updated Edit features with the Editor widget, Editor widget with configurations, and Edit features in 3D with the Editor widget samples.

Currently, the snapping functionality offered in the Editor widget does not provide a UI similar to that of the Sketch widget. This behavior will change in upcoming releases with an updated UI to help with configuring snapping options.

Other improvements

The Editor widget will now automatically disable the view's popup when selecting a feature to edit. It is no longer necessary to add a line similar to the following:

Use dark colors for code blocksCopy
1
view.popup.autoOpenEnabled = false; // no longer necessary to add when using the Editor to edit existing features

FeatureForm

Additional input types have been added to FormTemplate field elements. These input types include:

API keys

In version 4.18, we added support for a global API key to use with Location Services. Version 4.19 builds on top of that and makes it easier to use by supporting more fine-grained control of API keys, easier to work in conjunction with ArcGIS Identity, as well as improving default services when API key is used.

3D updates

Shadow highlight

Identify the shadow of individual 3D objects, such as buildings or trees, when clicking on the feature or calling highlight(). Combining the new shadow highlight with the Daylight widget you can determine how each building contributes to a certain shadowed area, for any season and time of day. You can configure the strength of the highlight by setting the new SceneView property highlightOptions.shadowColor and additional opacity settings to allow you to differentiate shadows that overlap with the highlighted one.

Shadow highlight

Line and polygon transformations

Interactively scale and rotate line and polygon geometries using the Sketch and Editor widgets. Clicking on a line or polygon being updated will toggle between reshaping and transforming the feature. The available modes can be customized through the SketchViewModel.defaultUpdateOptions settings. To scale a geometry by keeping its proportions, keep the CTRL button pressed during the transformation.

Line and polygon transformations

Improved rendering quality

A new lighting and shading model adds more contrast and definition to your 3D content. With the 4.19 release, existing scenes will benefit from this visual improvement when SceneView.qualityProfile is set to medium or high. Additionally, objects with Physically-Based Rendering (PBR) materials, such as used in WebStyleSymbols, display light reflections on glass or metallic surfaces.

Improved rendering quality

Magnifier

Added a Magnifier to the MapView and SceneView, which displays a portion of the view as a magnified image. The Magnifier can improve the editing and drawing experience of applications utilizing the Sketch and Editor widgets, especially when pairing with the new snapping functionality.

magnifier

Floor awareness

Floor-aware maps and layers

We introduced floor awareness, which brings indoor GIS data representing floor plan features to your maps and layers. You can now specify the floorInfo property in your WebMap, WebScene, FeatureLayer, or SceneLayer to make your map or scene floor-aware.

FloorFilter widget

The FloorFilter widget filters features from floor-aware layers to control visualization in both MapView and SceneView. Once you have defined the floorInfo for a map or scene, you can use the FloorFilter widget to interactively filter your floor plan data.

floorfilter-widget

Widget updates

FeatureTable

Filter the table by geometry or extent

It is now possible to filter out what is displayed within the table. This functionality is handled via the filterGeometry property. It works by passing in a Geometry and any features that intersect it are displayed within the table. You can see how this works in the updated FeatureTable widget with map sample.

filter-geometry-table

Improved theme compatibility

The FeatureTable widget was enhanced to improve compatibility with the API themes provided out-of-the-box. The FeatureTable now takes advantage of the dark theme, which was not available in previous releases. The light-theme compatibility was also improved.

dark theme feature table

The Popup widget now dynamically displays content in the header and footer to handle longer strings. This can be seen when displaying action text with a large amount of characters.

4.184.19
popup-actions-footer-418 popup-actions-footer-419

In addition to the UI update mentioned above, two additional title and description properties were added for the Attachments, Fields, and Media content elements. This is shown below in the various screen captures.

AttachmentsFieldsMedia
popup-attachment-title-description popup-fields-title-description popup-media-title-description

Directions

The Directions widget now allows a Time Unspecified departure option. This uses the average travel time to calculate estimated travel durations.

Promises

All widgets now support the following methods: when(), isResolved(), isFulfilled(), and isRejected(). You can use these methods to return a promise when the widget is created or to verify if the widget was created successfully.

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
// Add the BasemapGallery to the view only one the widget has been instantiated
const bmGallery = new BasemapGallery();
bmGallery.when(() => {
  // This function will execute once the promise is resolved
  view.ui.add(bmGallery);
}, (error) => {
  // This function will execute if the promise is rejected due to an error
});

Layer updates

OGCFeatureLayer spatial references

The OGCFeatureLayer now supports OGC API - Features - Part 2, which provides support for additional spatial references. Previously only WGS84 was supported. Now, all OGCFeatureLayers will work in WGS84 and WebMercator, along with any other spatial references provided by the service.

MapNotesLayer - editing support

The MapNotesLayer can now be edited if it was created in the new Map Viewer. Map notes can be added, updated, and deleted - allowing you to easily sketch, add, remove, or update notes from any map, then persist your changes using WebMap.save(). Map notes created with Map Viewer Classic can be displayed, but the map notes cannot be modified or accessed with this class. Check out the MapNotesLayer sample to see it in action.

MNLsample

GroupLayer

GroupLayer now supports minScale and maxScale properties. The 2D MapView will support scale range defined for a group layer. For a child layer in a group to be visible, the view scale should intersect the scale range defined for the child as well as all its parent group layers.

VectorTileLayer - support for expressions

At this release, we added a full support for lookup, ramp, variable binding, color, math (with an exception of distance), and zoom expressions and a limited support for type, feature data, decision, and string expressions. We will continue to add support for all expressions in coming releases.

Browse cluster features

We added Browse features as a new default action to the cluster popup. This allows you to browse and select individual features included in a cluster directly from the cluster popup. The Zoom to action was updated to zoom to the extent of a cluster's features. You can explore these new actions in any of the cluster samples. Also, point clustering is no longer in beta.

cluster popup actions

Data visualization guide

The data visualization guide was revamped with more than 20 new conceptual topics and four chapters. Explore the guide to learn about visualization best practices, the various layer styles available in the JS API, and browse the hundreds of symbols and color ramps provided for easy copy/paste use in your apps.

data viz chapter

Smart mapping updates

Added normalizationType to support various transformations in histogram and summary statistics. Includes support for normalization-total, log, natural-log, and square-root. Check out the histogram sample to explore these new normalization types.

We also added 20 new color ramps to the Color ramps guide.

IdentityManager update

Two methods, enablePostMessageAuth and disablePostMessageAuth, were added to the IdentityManager to help make passing authentication from an embedded application using an iframe to its host application easier to manage. This is necessary as problems could arise if a user is logged into a web application containing an embedded application that is not public. If this scenario occurs, its easier to pass the already-provided credentials to the secured embedded application.

rest modules

We've ported the majority of Tasks functionality to simple functional rest modules. This will make it easier to incorporate into a more modular app design, and also reduce unnecessary dependencies (you only import what you want). The next release will see the rest of the Tasks ported over, and then we will deprecate Tasks. Note that esri/layers/support/AttachmentInfo has been moved to esri/rest/query/support/AttachmentInfo.

Added classes, properties, methods, events

Deprecated classes, properties, methods, events

Breaking changes

  • The IdentityManager's setRedirectionHandler method and useSignInPage property were removed at 4.19. This was a result of Enterprise Portal apps no longer making use of this functionality beginning with the upcoming Enterprise 10.9.1 release.
  • The InputField and FieldElement hint property has been updated to display a temporary placeholder for text and number inputs for both TextAreaInput and TextBoxInput. Prior to this, whatever was set in the FieldElement's hint would display as a tooltip while hovering over the input field.
  • In order to disable any default actions in a Popup, it is now necessary to set includeDefaultActions to false. Prior to version 4.19, this was not necessary. All that was needed to remove a default action, e.g. the "Zoom to" button, was to directly set the popup's actions. This would disable the "Zoom to" button from displaying.
  • FieldElement input types of Input and TextInput have been removed in favor of exposing only their subclass types. These subclass types include TextAreaInput, TextBoxInput, and DateTimePickerInput. In addition to the latter three types, some additional new input types were also included at 4.19. These include BarcodeScannerInput, RadioButtonsInput, and ComboBoxInput. No properties or functionality was removed with Input and TextInput. These two classes' properties are now accessible directly from their subclasses.
  • esri/layers/support/AttachmentInfo has been moved to esri/rest/query/support/AttachmentInfo. While the older class will still work with JavaScript, you will need to update the reference to the new class location to get the correct typings with TypeScript.
  • The @renderable decorator has been deprecated and removed in the esri widgets helper class. Nothing else is required by the developer as widgets should still work as expected.
  • If extending a class that implements Accessor, it is no longer necessary to use dependsOn with the @property decorator when defining an Accessor property.
  • The Custom Recenter widget sample has been removed from the SDK samples. For more information visit the Custom UI basics guide page.
  • Removed the requestOptions property from the following tasks (requestOptions is still available as an optional method parameter): ClosestFacilityTask, FindTask, GeometryService, IdentifyTask, ImageIdentifyTask, ImageServiceIdentifyTask, PrintTask, RouteTask, ServiceAreaTask.

The following classes, methods, properties and events have been deprecated for at least 2 releases and have now been removed from the API:

Class/Property/Method/EventAlternate optionVersion deprecated
ProjectParameters.outSRProjectParameters.outSpatialReference4.4
BasemapToggle.titleVisibleBasemapToggle.visibleElements.title4.15
AreaMeasurement2DViewModel.clearMeasurement()AreaMeasurement2DViewModel.clear()4.16
AreaMeasurement2DViewModel.newMeasurement()AreaMeasurement2DViewModel.start()4.16
AreaMeasurement3DViewModel.clearMeasurement()AreaMeasurement3DViewModel.clear()4.16
AreaMeasurement3DViewModel.newMeasurement()AreaMeasurement3DViewModel.start()4.16
DistanceMeasurement2DViewModel.clearMeasurement()DistanceMeasurement2DViewModel.clear()4.16
DistanceMeasurement2DViewModel.newMeasurement()DistanceMeasurement2DViewModel.start()4.16
DirectLineMeasurement3DViewModel.clearMeasurement()DirectLineMeasurement3DViewModel.clear()4.16
DirectLineMeasurement3DViewModel.newMeasurement()DirectLineMeasurement3DViewModel.start()4.16
PrintTemplate.preserveScalePrintTemplate.scalePreserved4.16
SliceViewModel.clearSliceSliceViewModel.clear()4.16
SliceViewModel.newSliceSliceViewModel.start()4.16

Please refer to the Breaking changes guide topic for a complete list of breaking changes across all releases of the 4x API.

Bug fixes and enhancements

  • BUG-000126808: Fixed an issue where web maps with custom symbology would not carry this symbology over correctly in the hosted web application.
  • BUG-000131005: Fixed an issue where clicking on the view unexpectedly changes the symbology of features represented in a Legend that is embedded in a LayerList panel.
  • BUG-000131546: Fixed an issue where selecting features using the Editor widget would fail at large scales if the service's spatial reference does not match the map's spatial reference.
  • BUG-000134522: Fixed an issue where the UniqueValueRenderer would fail to display PictureMarkerSymbol graphics when attempting to load over a thousand images.
  • BUG-000135208: Pop-ups now display related records in a many-to-many (M-N) relationship correctly.
  • BUG-000135526: Fixed an issue where clicking on the view unexpectedly changes the symbology of features represented in a Legend that is embedded in a LayerList panel.
  • BUG-000135733: Fixed an issue where a Graphic with an Extent geometry containing a TextSymbol would disappear from the map at certain zoom levels.
  • BUG-000135869: Fixed an issue where the undo action executed using the 'z' key on a keyboard is not respected when editing features with the Editor widget.
  • BUG-000135930: Fixed an issue where a feature is flashed when refresh() is called after applyEdits() resolves.
  • BUG-000136086: Fixed an issue in the documentation where the return type of the added and vertices.coordinates properties of the Sketch widget's VertexAddEventInfo typedef returned Graphic[] instead of Number[].
  • BUG-000136200: Fixed an issue where the Expand would not close by pressing the Escape key. We added the closeOnEsc property so users can configure when to allow this, but it is enabled by default to improve accessibility.
  • BUG-000137044: Fixed an issue where multipoint features in a FeatureLayer are cut off along tile edges.
  • BUG-000137240: Fixed an issue where load times for applications with over 20,000 graphics were significantly slower when compared to 3.x applications.
  • BUG-000137309: Fixed an issue where the Search.suggestions returned slightly inconsistent results.
  • BUG-000137382: Fixed an issue where the OGCFeatureLayer request would fail on servers that have a "limit" maximum less than 10,000.
  • BUG-000137625: Fixed an issue where the stroke width of a line or polygon CIMSymbol would be inconsistent with the stroke of the symbol in the Legend widget.
  • BUG-000136445: Fixed an issue where attributes are not updated when FeatureLayer.applyEdits is called continuously.
  • ENH-000128899: Added support for a Magnifier in the MapView and SceneView.
  • GEONET-250539 and GEONET-251318: Fixed an issue where very few features are labeled when timeExtent is set on the view or filter is set on the layer view.
  • GEONET-1027073: Fixed an issue where tile layers with transparency flash when interacting with a view.
  • Fixed an issue where CIMSymbols would get cut off at tile boundaries.
  • Fixed an issue where KMLLayer with HTML in its title does not display properly with the LayerList widget.
  • Fixed an issue where a CIMSymbol with only a CIMPictureMarker symbol layer would not render in the GraphicsLayer.
  • Fixed an issue where critical dependency warnings would occur when building the API with ES modules and webpack.
  • Fixed an issue where requests were not being made initially when WMSLayer sublayers were toggled in the LayerList widget.
  • Fixed an issue where the Print widget allowed illegal characters in the MAP_ONLY width and height.
  • Fixed an issue where the ScaleBar widget was showing an incorrect scale for non-Earth GCS.
  • Fixed an issue with printing layers from a MapServer if the map service supports dynamic layers.
  • Fixed an issue with rendering centroids. For multi-part polygons, polygon centroids now render in the center of the largest ring. Previously, they were rendered using the centroid of all combined rings, which had undesirable results.
  • Fixed an issue with the CIMSymbol where the shiftOddRows property was not supported in the markerPlacement object on a polygon symbol.
  • Fixed an issue with the DictionaryRenderer, where call out lines would be added to each symbol in a SceneView, even if the symbol had elevation set.
  • Fixed an issue with the DictionaryRenderer, where the configuration and text fields were being treated as mandatory, when they should have been optional.
  • Fixed an issue with the Directions widget where the suggestions would get truncated when using bottom placement.
  • Fixed an issue with the OGCFeatureLayer where features were not automatically highlighted when selected.
  • Fixed an issue with the OGCFeatureLayer where the Popup would re-request all data if there were missing attributes.
  • Fixed an issue with the OGCFeatureLayer where unnecessary additional requests were being made for some server types.
  • Fixed an issue with the WMTSLayer where it would load all sublayers even if a sublayer was preselected. For large layers, this would cause a long lag in load time.
  • Fixed an issue where a decreased number of labels were being displayed than expected. This was caused by the improvements added for detecting label collisions.
  • Enhanced the cimSymbolUtils by adding a clockwise option for the getCIMSymbolRotation and applyCIMSymbolRotation methods.
  • Enhanced the Directions widget by adding a Time Unspecified departure option.
  • Enhanced the Gamepad so that navigation will only work over https.
  • Enhanced the Popup by ensuring that there was sufficient contrast between the text and background color when the feature menu is open.
  • Enhanced the Print widget and PrintTask to support printing the background color of MapViews and WebMaps. This requires ArcGIS Server 10.9 or later.
  • Enhanced the scaleCIMSymbolTo method by adding a scaleOptions parameter to allow users to preserve the outline width of their symbol when scaleSymbolsProportionally is false.

Additional packages

Version 4.19 of the ArcGIS Maps SDK for JavaScript uses ArcGIS Arcade 1.13 (since 4.19).

How to access the SDK

  • The API library is available on both CDN and npm, Read more at Install and set up.
  • For supported versions, you can also download both the documentation and the API library. These downloads are typically available 3-4 weeks after release.

Previous releases

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.