import type { Ary } from '../../internal/types/tools/index.js'; declare global { interface Array { /** * Takes elements from the array until the predicate returns `true`. * @param pred The predicate function. * * @example * ```typescript * [1, 2, 3, 4, 5].takeUntil((x) => x === 3); // => [1, 2] * [1, 2, 3, 4, 5].takeUntil((x) => x === 10); // => [1, 2, 3, 4, 5] * ``` */ takeUntil: ( this: AS, pred: (value: AS[number], index: number, array: AS) => boolean, ) => Ary.Mutate; } interface ReadonlyArray { /** * Takes elements from the array until the predicate returns `true`. * @param pred The predicate function. * * @example * ```typescript * [1, 2, 3, 4, 5].takeUntil((x) => x === 3); // => [1, 2] * [1, 2, 3, 4, 5].takeUntil((x) => x === 10); // => [1, 2, 3, 4, 5] * ``` */ takeUntil: ( this: AS, pred: (value: AS[number], index: number, array: AS) => boolean, ) => Ary.Mutate; } } //# sourceMappingURL=takeUntil.d.ts.map