['1', `2`, `3`, `4`, `5`]
[
{
number: '3',
name: 'Vasja',
},
{
number: '5',
name: 'Igor',
}
]
['1', `2`, `4`]
numbers.filter(n => !objects.some(m => m.number === n))
numbers.filter(function(n) {
return !this.has(n);
}, new Set(objects.map(n => n.number)))
numbers.filter(((nums, n) => !nums.includes(n)).bind(null, objects.map(n => n.number)))
Object.values(objects.reduce(
(acc, n) => (delete acc[n.number], acc),
numbers.reduce((acc, n) => (acc[n] = n, acc), {})
))
Array.from(objects.reduce(
(acc, n) => (acc.delete(n.number), acc),
new Map(numbers.map(n => [ n, n ]))
).values())