Answer the question
In order to leave comments, you need to log in
If the way to iterate over an object with this property is = options[788085][]: (2) ["7222652", "8237257"]?
There is an object
obj = {
options[788085][]: (2) ["7222652", "8237257"]
}
Answer the question
In order to leave comments, you need to log in
I read fortunes on the coffee grounds and saw there that you mean the following structure (because the code you provided is not valid):
obj = {
options: { // или тут массив с примерно миллионом элементов
788085: ["7222652", "8237257"]
}
};
// Тогда вот так:
obj.options[788085].forEach(item => console.log(item));
// Или, возможно, так:
obj[options[788085]].forEach(item => console.log(item));
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question