'use strict'; // eslint-disable-line
const CrawlKit = require('crawlkit');

const baseURL = 'https://www.google.com';
const crawler = new CrawlKit(baseURL);

crawler.addRunner('title', {
    getCompanionFiles: () => [],
    getRunnable: () => {
        return function extractTitle() {
            window.callPhantom(null, document.title);
        };
    },
});

crawler.crawl(true).pipe(process.stdout);

@@ -352,24 +352,39 @@
     %7D,%0A%7D);%0A%0A
+const stream = 
 crawler.craw
@@ -390,16 +390,115 @@
 wl(true)
+;%0Astream.on('end', () =%3E %7B%0A    /* eslint-disable no-console */%0A    console.log('done!');%0A%7D);%0Astream
 .pipe(pr

improve streaming example