dimanche 14 avril 2019

How to update specific property on array of object?

Say "I initialized an array with predefined values like this" in my controller

  data: A([
    {
      lat: 14.5619175,
      lng: 121.0197196,
      title: "Jazz Mall",
      open: false
    },
    {
      lat: 14.5660656,
      lng: 121.0295681,
      title: "Avalue Residences",
      open: false
    },
    {
      lat: 14.5661493,
      lng: 121.0282417,
      title: "Century City",
      open: false
    }
  ])

Now, How can I update values to something like

title: "Jazz Mall" to title: "Value has been change"




Aucun commentaire:

Enregistrer un commentaire