expression (Mapbox)

An expression is a formula for calculating a value in a layer, using the Mapbox GL expression syntax. Expressions can retrieve property values, perform arithmetic calculations, respond to the current zoom level, or choose between different options depending on a value. Expressions are expressed as an array, where the first element defines the type of expression. For example, ['get', 'name'] retrieves the name attribute from a feature.

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