---
title: "ConstantExpression | JavaScript maps SDK"
description: "Documentation for MapTiler SDK"
---

> For AI agents: a documentation index is available at [/llms.txt](https://docs.maptiler.com/llms.txt). Markdown versions of all pages are available by appending .md to any URL.

# Type Alias ConstantExpression

type ConstantExpression \= {  
    [\_globalState](#_globalstate): [Record](https://docs.maptiler.com/sdk-js/api-reference/types/Externals.Record/)<string, any\>;  
    [evaluate](#evaluate): (  
        globals: [GlobalProperties](https://docs.maptiler.com/sdk-js/api-reference/types/GlobalProperties/),  
        feature?: [Feature](https://docs.maptiler.com/sdk-js/api-reference/types/Feature/),  
        featureState?: [FeatureState](https://docs.maptiler.com/sdk-js/api-reference/types/FeatureState/),  
        canonical?: [ICanonicalTileID](https://docs.maptiler.com/sdk-js/api-reference/interfaces/ICanonicalTileID/),  
        availableImages?: string\[\],  
    ) \=> any;  
    [globalStateRefs](#globalstaterefs): Set<string\>;  
    [kind](#kind): "constant";  
}

##### Index

### Properties[](#properties)

[\_globalState](#_globalstate) [evaluate](#evaluate) [globalStateRefs](#globalstaterefs) [kind](#kind)

## Properties[](#properties-1)

### `Readonly`\_globalState[](#_globalstate)

\_globalState: [Record](https://docs.maptiler.com/sdk-js/api-reference/types/Externals.Record/)<string, any\>

### `Readonly`evaluate[](#evaluate)

evaluate: (  
    globals: [GlobalProperties](https://docs.maptiler.com/sdk-js/api-reference/types/GlobalProperties/),  
    feature?: [Feature](https://docs.maptiler.com/sdk-js/api-reference/types/Feature/),  
    featureState?: [FeatureState](https://docs.maptiler.com/sdk-js/api-reference/types/FeatureState/),  
    canonical?: [ICanonicalTileID](https://docs.maptiler.com/sdk-js/api-reference/interfaces/ICanonicalTileID/),  
    availableImages?: string\[\],  
) \=> any

### globalStateRefs[](#globalstaterefs)

globalStateRefs: Set<string\>

### kind[](#kind)

kind: "constant"
