Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

203
Views
Basic javascript webscraper throws error / XPATH not resolved?

I try to write a webscraper with the Puppeteers library. It worked properly on amazon.com - but with another page (coinhall.org) I get an error that I can't resolve. Can anyone point me in the right direction here?

const [el2] = await page.$x('//*[@id="root"]/div/div[4]/div/div[1]/div[1]/div[2]/div[1]/div[2]/div[1]/div[1]');
const txt = await el2.getProperty('textContent');
const rawTxt  = txt.jsonValue();

Error:


const txt = await el2.getProperty('textContent');
                         ^

TypeError: Cannot read properties of undefined (reading 'getProperty')

Seems as if el12 doesn't get its value somehow, right? Double checked the XPATH, it's correct though.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!