1.0.0 • Published 4 years ago

splice-clone v1.0.0

Weekly downloads
3
License
ISC
Repository
github
Last release
4 years ago

splice-clone

Splice and clone javascript arrays

NPM

Usage

Takes an array as first argument, followed by standard Array.prototype.splice arguments.

import spliceClone from 'splice-clone';

const arr = [1, 2, 3];

const arr2 = spliceClone(arr, 1, 0, 1.5);
// arr2 = [1, 1.5, 2, 3]
1.0.0

4 years ago