TomTom Maps for JavaScript
    Preparing search index...

    Type Alias SetStyleOptions

    Options accepted by TomTomMap.setStyle.

    type SetStyleOptions = {
        resetState?: boolean;
    }
    Index
    resetState?: boolean

    Whether to drop the SDK state instead of carrying it over to the new style.

    • false (default): module data and configuration, filters and the style parts of the previous style (traffic, hillshade) are restored onto the new style.
    • true: a clean switch. Modules re-bind to the new style with default configuration and nothing shown, and only the style parts named in the new style input are loaded.

    The map language is not SDK state: it is re-applied in both cases, and only TomTomMap.setLanguage changes it.

    Registered StyleChangeHandlers run in both cases and receive the value in their StyleChangeContext.

    false