zeed
    Preparing search index...

    Function arrayFilterInPlace

    • Filter an array in-place using fn and return the same array instance. This replaces the array contents with the filtered result.

      Type Parameters

      • T

        element type

      Parameters

      • arr: T[]

        array to filter in-place

      • fn: (el: T) => boolean

        predicate to determine which elements to keep

      Returns T[]

      the same array instance after filtering