0.0.2 • Published 10 years ago

head-scraper v0.0.2

Weekly downloads
1
License
MIT
Repository
github
Last release
10 years ago

Head Scraper

Scrape the <head> of webpages for <title>, <meta>, and <link>s. Uses htmlparser2, cogent, head-parser and head-scraper.

Example

var co = require('co')
var scrape = require('head-scraper')

co(function* () {
  var data = yield* scrape('https://github.com')
  data.title === 'GitHub blah blah blah'
  data.description === 'GitHub is the best blah blah blah'
  data.og.title === 'GitHub blah blah blah facebook'
})()