This is the documentation of version 0.62.2. Go to the latest version, 1.0.0-rc.5.
TomTom Maps for JavaScript
    Preparing search index...

    Type Alias LabelConfig

    How a module's text labels look. Sizes and widths are in pixels, and every field also takes a MapLibre expression.

    type LabelConfig = {
        color?: DataDrivenPropertyValueSpecification<string>;
        font?: DataDrivenPropertyValueSpecification<MapFont[]>;
        haloColor?: DataDrivenPropertyValueSpecification<string>;
        haloWidth?: DataDrivenPropertyValueSpecification<number>;
        opacity?: DataDrivenPropertyValueSpecification<number>;
        size?: DataDrivenPropertyValueSpecification<number>;
    }
    Index
    color?: DataDrivenPropertyValueSpecification<string>

    Text colour.

    font?: DataDrivenPropertyValueSpecification<MapFont[]>

    Font faces, the first one available wins.

    haloColor?: DataDrivenPropertyValueSpecification<string>

    Colour of the halo drawn around the text, for legibility.

    haloWidth?: DataDrivenPropertyValueSpecification<number>

    Width of the halo, in pixels.

    opacity?: DataDrivenPropertyValueSpecification<number>

    Text opacity, 0 (transparent) to 1 (opaque).

    size?: DataDrivenPropertyValueSpecification<number>

    Font size, in pixels.