UNPKG

333 BJavaScriptView Raw
1import size from './size';
2/**
3 * Gets a part of array.
4 * @param x an array (updated)
5 * @param i start index (0)
6 * @param I end index (end)
7 * @returns x
8 */
9function slice$(x, i = 0, I = x.length) {
10 x.copyWithin(0, i, I);
11 x.length = size(x, i, I);
12 return x;
13}
14export default slice$;
15//# sourceMappingURL=slice$.js.map
\No newline at end of file