-
Notifications
You must be signed in to change notification settings - Fork 0
remove
Subhajit Sahu edited this page Feb 4, 2021
·
14 revisions
entries.remove(x, k);
// x: entries
// k: key
const entries = require("extra-entries");
var x = [["a", 2], ["b", 4], ["c", 6], ["d", 8]];
[...entries.remove(x, "b")];
// [ [ "a", 2 ], [ "c", 6 ], [ "d", 8 ] ]
[...entries.remove(x, "d")];
// [ [ "a", 2 ], [ "b", 4 ], [ "c", 6 ] ]