export function slidingWindows(array, size, { step = 1, partial = false } = {}) {
    if (!Number.isInteger(size) || !Number.isInteger(step) || size <= 0 || step <= 0) {
        throw new RangeError("Both size and step must be positive integer.");
    }
    const length = Math.floor((array.length - (partial ? 1 : size)) / step + 1);
    const result = [];
    for (let i = 0; i < length; i++) {
        result.push(array.slice(i * step, i * step + size));
    }
    return result;
}
//# sourceMappingURL=data:application/json;base64,[encoded data, 4104 characters]