head-scraper
v0.0.2
Published
scrape the <head> of webpages for <title>, <meta>, and <link>s
Downloads
3
Readme
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'
})()