Issue
I'm making an ionic project on where I got an incoming array made of key:value object like:
is possible to separate those values in 3 different arrays: date[] speed[] and altitude[]?
Solution
Assuming you have data in this format:
const data = [{a: 10, b: 20, c: 30}, {a: 100, b: 200, c: 300}, {a: 1000, b: 2000, c: 3000}];
const a = data.map((d) => {
return d.a
});
const b = data.map((d) => {
return d.b
});
const c = data.map((d) => {
return d.c
});
Answered By - Ritesh Waghela
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.