sathish316 / scrapify

ScrApify is a library to build APIs by scraping static sites and use data as models or JSON APIs. It powers APIfy which is used to create JSON APIs from any html or wikipedia page
http://apify.heroku.com/resources
143 stars 16 forks source link

Page object instead of Class including Scrapify::Base #5

Closed sathish316 closed 12 years ago

sathish316 commented 12 years ago

Is there a way to extract data like this:

page = Page.new('http://www.wikipedia.com/list', 'name', {
 'name' => {'css' => 'dt'},
 'description' => {'css' => 'dd'},
})

instead of

class WikiList
  include Scrapify::Base

  key :name
  attribute :name, css: 'dt'
  attribute :description, css: 'dd'
end