@lucid-softworks/array-insert
v0.1.0
Published
Insert values at an array index without mutation.
Maintainers
Readme
@lucid-softworks/array-insert
Insert values at a clamped index without mutating the input. Negative indexes are relative to the end.
import { insertAt } from "@lucid-softworks/array-insert";
insertAt([1, 4], 1, 2, 3); // [1, 2, 3, 4]