@extra-array/splice
@extra-array/splice
npm i @extra-array/splice
@extra-array/splice

@extra-array/splice

A collection of functions for working with Arrays.

by nodef

2.10.19 (see all)License:MITTypeScript:Built-In
npm i @extra-array/splice
Readme

Removes or replaces existing values. 📦 😺 🏃‍♂️ 📼 🌔 📜 📰 📘

Alternatives: splice, splice$.

This is part of package extra-array.


array.splice(x, i, [n], ...vs);
// x:  an array
// i:  remove index
// n:  number of values to remove (rest)
// vs: values to insert
const array = require("extra-array");

var x = [1, 2, 3, 4, 5];
array.splice(x, 2);
// [ 1, 2 ]

array.splice(x, 2, 2);
// [ 1, 2, 5 ]

array.splice(x, 2, 2, 30, 40);
// [ 1, 2, 30, 40, 5 ]


References

Downloads/wk

0

GitHub Stars

16

LAST COMMIT

9mos ago

MAINTAINERS

1

CONTRIBUTORS

3

OPEN ISSUES

0

OPEN PRs

0
VersionTagPublished
2.10.19
latest
9mos ago
No alternatives found
No tutorials found
Add a tutorial
No dependencies found

Rate & Review

100
No reviews found
Be the first to rate