New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

read-art

Package Overview
Dependencies
Maintainers
1
Versions
66
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

read-art - npm Package Compare versions

Comparing version 0.4.0 to 0.4.1

6

HISTORY.md

@@ -0,1 +1,7 @@

# 2015/12/18
- only fetch body when uri is provided but html is empty
- fix the links of img,a,object,embed... - relative to absolute
- customize selectors
- refactor: extract data
# 2015/12/09

@@ -2,0 +8,0 @@ - Supports `cheerio` output type. @entertainyou

2

lib/reader.js

@@ -127,3 +127,3 @@ "use strict";

} else {
isObject = util.isObject(extract);
isObject = Object.prototype.toString.call(extract) == '[object Object]';
if (isObject) {

@@ -130,0 +130,0 @@ props = Object.keys(extract);

{
"name": "read-art",
"version": "0.4.0",
"version": "0.4.1",
"description": "Scrape/Crawl article from any site automatically. Make any web page readable, no matter Chinese or English.",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -156,3 +156,4 @@ read-art [![NPM version](https://badge.fury.io/js/read-art.svg)](http://badge.fury.io/js/read-art) [![Build Status](https://travis-ci.org/Tjatse/node-readability.svg?branch=master)](https://travis-ci.org/Tjatse/node-readability)

<a name="selectors" />
Some times we wanna extract article somehow, e.g. pick the title of `.article>h3` as title, and pick `.article>.author` as the author data:
## Extract Selectors
Some times we wanna extract article somehow, e.g.: pick the text of `.article>h3` as title, and pick `.article>.author` as the author data:
```javascript

@@ -182,3 +183,3 @@ read({

**Notes** The binding data will be an object if the `extract` option is an array object, but `content` depends on the `output` option.
**Notes** The binding data will be an object or array (object per item) if the `extract` option is an array object, `title` and `content` will override the default extracting methods, and the output of `content` depends on the `output` option.

@@ -185,0 +186,0 @@ <a name="cus_sets" />

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc