I have to merge 2 array of object from rest api calls.
They are like: `[{date: date, name: name}, ...]`
Let's call them A array and B array. 

If in the A arrays and B arrays have the same date, the final array-s object should like look this: `[{date: date, nameA: nameA, nameB: nameB}]`

If they dont, just insert insert and object like this: `[{date: dateA, nameA: nameA}]`

For example:

```
arrayA = [
    {
      date: 2017-01-01, 
      name: 'New Year Eve'}
    },
    {
      date: 2017-02-02, 
      name: 'feb2'
  }
]

arrayB = [
    {
      date: 2017-01-01, 
      name: 'New Year Eve'}
    },
    {
      date: 2017-03-03, 
      name: 'march3'
  }
]

```

The final array should look like this:

```
finalArray = [{
    date: 2017 - 01 - 01,
    nameA: 'New Year Eve',

    nameB: 'New Year Eve'
},
{
    date: 2017 - 02 - 02,
    nameA: 'feb2'
},
{
    date: 2017 - 03 - 03,
    nameB: 'march3'
}

```

]

And the objects with shared date can be in different position in the array, so i can't check simple like

```
arrayA[0].date === arrayB[0].date

```