• Returns the element types of the given array

    Parameters

    • Optionalarray: null | any[] | readonly any[]

      the array to check

    Returns string[] | undefined

    the element types of the given array

    getTypeof(['foo', 'bar']);    // ['string', 'string']