title: Group object values by date
body: <p>I'm trying to make an upcoming event on react native, I have this object</p>
  <pre><code>const calendatData = [
          {
              &quot;data&quot;: [
                {
                  &quot;id&quot;: 25,
                  &quot;title&quot;: &quot;Spotify&quot;,
                  &quot;name&quot;: &quot;Family&quot;,
                  &quot;service_id&quot;: 1,
                  &quot;repetition&quot;: &quot;Monthly&quot;,
                  &quot;price&quot;: &quot;79000&quot;,
                  &quot;upcoming_date&quot;: [
                    &quot;2020-08-07T13:35:44.606Z&quot;
                  ]
                },
                {
                  &quot;id&quot;: 26,
                  &quot;title&quot;: &quot;Netflix&quot;,
                  &quot;name&quot;: &quot;Mobile&quot;,
                  &quot;service_id&quot;: 2,
                  &quot;repetition&quot;: &quot;Monthly&quot;,
                  &quot;price&quot;: &quot;49000&quot;,
                  &quot;upcoming_date&quot;: [
                    &quot;2020-08-18T13:35:44.600Z&quot;,
                    &quot;2020-08-07T13:35:44.606Z&quot;
                  ]
                },
                {
                  &quot;id&quot;: 27,
                  &quot;title&quot;: &quot;iTunes&quot;,
                  &quot;name&quot;: &quot;Weekly Special&quot;,
                  &quot;service_id&quot;: 3,
                  &quot;repetition&quot;: &quot;Weekly&quot;,
                  &quot;price&quot;: &quot;22000&quot;,
                  &quot;upcoming_date&quot;: [
                    &quot;2020-08-07T13:35:44.606Z&quot;,
                    &quot;2020-08-14T13:35:44.606Z&quot;,
                    &quot;2020-08-21T13:35:44.606Z&quot;,
                    &quot;2020-08-28T13:35:44.606Z&quot;
                  ]
                }
              ],
              &quot;status&quot;: &quot;success&quot;
            }
      ]
  </code></pre>
  <p>what I've been trying to do is to extract that object based on the <code>upcoming_date</code>.
  the result that I need is like this</p>
  <pre><code>upcomingData = [
          {
              date: '2020-08-07',
              title: [
                  'Spotify',
                  'Netflix',
                  'iTunes'
              ]
          },
          {
              date: '2020-08-18',
              title: ['Netflix']
          },
          {
              date: '2020-08-14',
              title: ['iTuunes']
          },
          {
              date: '2020-08-21',
              title: ['iTuunes']
          },
          {
              date: '2020-08-28',
              title: ['iTuunes']
          }
  ]
  </code></pre>
  <p>On the same date, if there are multiple titles, it should be grouped under the same date in the object.</p>
  <p>instead what I got was this object</p>
  <pre><code>upcomingData = [
      {
          title: [
              &quot;Spotify&quot;,
              &quot;Netflix&quot;,
              &quot;iTunes&quot;,
          ],
          date : [
              &quot;2020-08-29&quot;,
              &quot;2020-08-07&quot;,
              &quot;2020-08-18&quot;,
              &quot;2020-08-07&quot;,
              &quot;2020-08-07&quot;,
              &quot;2020-08-14&quot;,
              &quot;2020-08-21&quot;,
              &quot;2020-08-28&quot;,
          ]
      }
  ]
  
  </code></pre>
  <p>I am new to this, and I'm aware that this is mostly about javascript knowledge, any help would be appreciated.</p>
  <p>thanks</p>