I'm having a array of object which I want to convert into object with key as the array of object's key's value and value as array of object's value's value.
Suppose I have an array like this
let arr = [
{name: "abcd", value: "xyz"},
{name: "pqr", value: "uvw"},
....
]
I want to create an object from this array like this.
obj = {
abcd: "xyz",
pqr: "uvw",
...
}
I want to take the value of the key and value and use them to create a new object. Is there any way to do this.?