Создаём новый массив:
const concat = (key, ...arrs) =>
Object.values([]
.concat(...arrs)
.reduce((acc, n) => (acc[n[key]] = acc[n[key]] || n, acc), {})
);
const newFirst = concat('hour', first, hours);
Дополняем существующий:
function add(key, target, ...sources) {
const keys = new Set(target.map(key));
sources.forEach(arr => arr.forEach(n => {
const k = key(n);
if (!keys.has(k)) {
keys.add(k);
target.push(n);
}
}));
return target;
}
add(n => n.hour, first, hours).sort((a, b) => a.hour - b.hour);