You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to achieve the following, I need to use for "loop of" (personal readability) on the array of elements from page.$$eval.
But the element of topics returned "empty".
Can you point what is the issue with my return mapped elements?
// Obtain and print list of search results
const topics = await page.$$eval(".results", (els) => {
// Extract text content from the actor cards
return els.map((el) => el);
});
for (let topic of topics){
log.debug(topic.innerHTML)
}
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I am trying to achieve the following, I need to use for "loop of" (personal readability) on the array of elements from page.$$eval.
But the element of topics returned "empty".
Can you point what is the issue with my return mapped elements?
Beta Was this translation helpful? Give feedback.
All reactions