2.0.1 • Published 1 year ago

web-parser v2.0.1

Weekly downloads
1
License
ISC
Repository
github
Last release
1 year ago

web-parser

This is a simple tool to parse websites using the jQuery interface, see cheerio API.

Simple usage

Print all <p> contents on the page:

const { parse } = require('web-parser');

const [$, $elements] = await parse('http://sample.com', 'p');
$elements.each((index, element) => {
  const $element = $(element);
  console.log(`index: ${index}, text: ${$element.text()}`);
});

Examples

Check examples folder!

2.0.1

1 year ago

2.0.0

1 year ago

1.0.1

8 years ago

1.0.0

8 years ago