there is such a data:
se = [
{
name:"",
type:"scatter",
data:["0.085", "-0.013", ""]
},
{
name:"",
type:"scatter",
data:["0.077", "-0.025", ""]
}
]
function BrandData(){
for (var i=0;i<se.length;iPP){
return {
name:se[i].name,
type:se[i].type,
data:se[i].data
}
}
};
I want to return each item in this data through a loop and keep its original format, that is,
{name: "Honda", type: "scatter", data: ["0.085", "- 0.013", "Honda"]}
but I can"t get all the content. I can only get the first item. How can I get each item of data when I"m learning js, at work?