@metreeca/core - v0.9.1
    Preparing search index...

    Function immutable

    • Creates an immutable deep clone.

      Only plain objects and arrays are recursively cloned. Other object types (Date, RegExp, Buffer, etc.) are returned as-is to preserve their functionality.

      Type Parameters

      • T

        The type of the value to be cloned

      Parameters

      • value: T

      Returns Readonly<T>

      A deeply immutable clone of value

      This function does not handle circular references and will cause infinite recursion leading to a stack overflow if the input contains cycles.