Universal Layer Manager
    Preparing search index...

    Function updateLayerOrder

    • Updates an array of layer IDs to include a new ID at a specific location.

      Parameters

      • currentOrder: string[]

        The existing array of IDs.

      • newLayerId: string

        The ID to insert.

      • Optionalindex: number

        (Optional) Specific index to insert at.

      • Optionalposition: "top" | "bottom"

        (Optional) 'top' (end of array) or 'bottom' (start of array).

      Returns string[]

      A new array with the order updated.