ブックマーク / www.npmjs.com (2)

  • cheerio

    cheerio Fast, flexible & lean implementation of core jQuery designed specifically for the server. const cheerio = require('cheerio'); const $ = cheerio.load('<h2 class="title">Hello world</h2>'); $('h2.title').text('Hello there!'); $('h2').addClass('welcome'); $.html(); //=> <html><head></head><body><h2 class="title welcome">Hello there!</h2></body></html> Note We are currently working on the 1.0.

    cheerio
  • cheerio-httpcli

    cheerio-httpcli - Node.js用WEBスクレイピングモジュール Node.jsでWEBページのスクレイピングを行う際に必要となる文字コードの変換と、cheerioによってパースしたHTMLをjQueryのように操作できるHTTPクライアントモジュールです。 特徴 取得先WEBページの文字コードを自動で判定してHTMLUTF-8に変換 UTF-8に変換したHTMLをjQueryのように操作可能 フォームの送信やリンクのクリックをエミュレート フォーム送信時のファイルアップロード対応 Node.jsお馴染みのコールバック形式と最近の流行であるプロミス形式どちらにも対応 同期リクエスト対応 $('a')要素のリンク先をファイルとしてダウンロード可能 $('img')要素画像をファイルとしてダウンロード可能(LazyLoad対応) $('a,img,script,link')

    cheerio-httpcli
    tadahiko_kawana
    tadahiko_kawana 2015/01/30
    こりゃ便利
  • 1