endless-slice

1.0.0-beta.6 • Public • Published

endless-slice

The slice method (Array.prototype.slice) but endless.

npm Build Status License

Instalation

npm add endless-slice

Usage

import slice from 'endless-slice';

const arr = [0, 1, 2, 3, 4, 5];

slice(arr); // => [0, 1, 2, 3, 4, 5]

slice(arr, 3); // => [3, 4, 5]

slice(arr, -2); // => [4, 5]

slice(arr, 2, 4); // => [2, 3]

slice(arr, -2, 2); // => [4, 5, 0, 1]

License

This project is licensed under Apache License, version 2.0.

/endless-slice/

    Package Sidebar

    Install

    npm i endless-slice

    Weekly Downloads

    2

    Version

    1.0.0-beta.6

    License

    Apache-2.0

    Unpacked Size

    17.2 kB

    Total Files

    9

    Last publish

    Collaborators

    • alexengrig