UNPKG

@extra-array/filter-at

Version:

Keeps values at given indices only.

7 lines (4 loc) 116 B
const array = require("extra-array"); var x = [2, 4, 6, 8]; array.filterAt(x, [1, 2]); array.filterAt(x, [1, 3]);