-
Notifications
You must be signed in to change notification settings - Fork 0
concat
Subhajit Sahu edited this page Dec 22, 2022
·
14 revisions
Append entries from all entries, preferring last.
function concat(...xs)
// xs: all entries
const entries = require('extra-entries');
var x = [["a", 1], ["b", 2]];
var y = [["c", 3], ["d", 4]];
[...entries.concat(x, y)];
// → [ [ "a", 1 ], [ "b", 2 ], [ "c", 3 ], [ "d", 4 ] ]
var z = [["d", 40], ["e", 50]];
[...entries.concat(x, y, z)];
// → [ [ "a", 1 ], [ "b", 2 ], [ "c", 3 ], [ "d", 40 ], [ "e", 50 ] ]