Scrape web pages in real time with Node.js

前端 未结 8 2220
闹比i
闹比i 2020-11-29 15:43

What\'s a good was to scrape website content using Node.js. I\'d like to build something very, very fast that can execute searches in the style of kayak.com, where one query

8条回答
  •  夕颜
    夕颜 (楼主)
    2020-11-29 16:34

    I see most answers the right path with cheerio and so forth, however once you get to the point where you need to parse and execute JavaScript (ala SPA's and more), then I'd check out https://github.com/joelgriffith/navalia (I'm the author). Navalia is built to support scraping in a headless-browser context, and it's pretty quick. Thanks!

提交回复
热议问题