puppeteer-crawl

Implement web page crawler scripts using a sane api on top of codeceptjs and puppeteer

Usage no npm install needed!

<script type="module">
  import puppeteerCrawl from 'https://cdn.skypack.dev/puppeteer-crawl';
</script>

README

puppeteer-crawl

Implement crawlers using a sane api on top of codeceptjs and puppeteer.

Example

In scripts/check24/login.js

module.exports = async function GotoCHECK24Main(ctx, I) {
  await I.amOnPage('https://www.check24.de');
  await I.wait(2);

  // Use any other codeceptjs commands from 
  // https://codecept.io/helpers/Puppeteer/
};

Then in src/crawl-script.js

const runScript = require('./runner');
const scriptFn = require('./scripts/check/login');

async function() {
    await runScript(scriptFn, './_out', {});
}()