I have an array like below
let result = ["a","b","c","d"]
then need to change like below how to do it Thank you for any help.
result = [
{
type: "a",
image: "a.jpg"
},
{
type: "b",
image: "b.jpg"
},
{
type: "c",
image: "c.jpg"
},
{
type: "d",
image: "d.jpg"
}
]