Answer the question
In order to leave comments, you need to log in
How to write arrays to an object?
Good afternoon: Cannot set property 'id' of undefined here is an error
if (this.categories) {
Object.entries(response).filter((item: any) => {
const array = (String(Object.keys(item[ 1]))).split(',');
if (item[1].category === this.categories) {
for (const k of array){
this.response[k] = Object.values(item[ 1]);
}
}
});
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question