console.log('--start');
crawler.run({
// startUrl: '/posts',
// filterUrlRegex: /$/,
onMatch: function (url, content) {
var match = content.match(/<title>(.*)<\/title>/i);
var title = match ? match[1] : '';
console.log(title + ' => ' + url);
},
onEnd: function() {
console.log('--end');
}
});