Check out example codes for "concat 2 arrays ignoring duplicate in typescript". It will help you in understanding the concepts better.

Code Example 1

var a = [1, 2, 3], b = [101, 2, 1, 10]
var c = a.concat(b.filter((item) => a.indexOf(item) < 0))

console.log(c) // c is [1, 2, 3, 101, 10]

Learn ReactJs, React Native from akashmittal.com