[{id: 1},{id: 2},{id: 2},{id: 3}]
[1,2,3]
[...new Set(arr.map(n => n.id))]
.Object.values(arr.reduce((acc, n) => (acc[n.id] = n.id, acc), {}))
// или
Array.from(new Map(arr.map(({ id }) => [ id, id ])).values())
// или
arr.map(n => n.id).filter((n, i, a) => i === a.indexOf(n))
// или
arr.reduce((acc, n) => (acc.includes(n.id) || acc.push(n.id), acc), [])