MAIDR JavaScript API
    Preparing search index...

    Function selectorString

    • A layer's selector, for a model that reads exactly one selector string.

      A string is returned as it is. A flat list of strings is the pre-4.0 shape joinSelectorList describes: it is joined, and the producer is told once that it should emit a string. Anything else is not a selector this kind of model can use, and gives undefined, which every such model already treats as "no highlight".

      Parameters

      • layer: Pick<MaidrLayer, "id" | "type" | "selectors">

        The layer whose selector is wanted

      Returns string | undefined

      One selector string, or undefined