[{"e":"01-25-01-006"},{"e":"01-02-05-001"}],
I have this.
[ 01-25-01-006,01-02-05-001 ]
, I need this format of array
[{"e":"01-25-01-006"},{"e":"01-02-05-001"}],
I have this.
[ 01-25-01-006,01-02-05-001 ]
, I need this format of array
You can use map
to get the desired outcome:
let data = [{
"e": "01-25-01-006"
}, {
"e": "01-02-05-001"
}];
console.log(data.map(entry => entry.e));