Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

metascraper

Package Overview
Dependencies
Maintainers
1
Versions
318
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metascraper - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

browser.js

2

dist/rules/publisher.js

@@ -62,2 +62,2 @@ 'use strict';

exports.default = [wrap((0, _createRule.meta)('meta[property="og:site_name"]')), wrap((0, _createRule.meta)('meta[name="application-name"]')), wrap((0, _createRule.meta)('meta[property="al:android:app_name"]')), wrap((0, _createRule.meta)('meta[property="al:iphone:app_name"]')), wrap((0, _createRule.meta)('meta[property="al:ipad:app_name"]')), wrap((0, _createRule.meta)('meta[name="Publisher"]')), wrap((0, _createRule.meta)('meta[name="twitter:app:name:iphone"]')), wrap((0, _createRule.meta)('meta[name="twitter:app:name:ipad"]')), wrap((0, _createRule.meta)('meta[name="twitter:app:name:googleplay"]'))];
exports.default = [wrap((0, _createRule.meta)('meta[property="og:site_name"]')), wrap((0, _createRule.meta)('meta[name="application-name"]')), wrap((0, _createRule.meta)('meta[property="al:android:app_name"]')), wrap((0, _createRule.meta)('meta[property="al:iphone:app_name"]')), wrap((0, _createRule.meta)('meta[property="al:ipad:app_name"]')), wrap((0, _createRule.meta)('meta[name="publisher"]')), wrap((0, _createRule.meta)('meta[name="Publisher"]')), wrap((0, _createRule.meta)('meta[name="twitter:app:name:iphone"]')), wrap((0, _createRule.meta)('meta[name="twitter:app:name:ipad"]')), wrap((0, _createRule.meta)('meta[name="twitter:app:name:googleplay"]'))];
{
"name": "metascraper",
"description": "A library to easily scrape metadata from an article on the web using Open Graph metadata, regular HTML metadata, and series of fallbacks.",
"version": "0.0.1",
"version": "0.0.2",
"repository": "git://github.com/ianstormtaylor/metascraper.git",
"main": "./dist/index.js",
"scripts": {

@@ -11,2 +10,12 @@ "build": "make dist",

},
"dependencies": {
"date.js": "^0.3.1",
"is-html": "^1.0.0",
"is-isodate": "0.0.1",
"is-url": "^1.2.1",
"isomorphic-fetch": "^2.2.1",
"jsdom": "^9.2.0",
"promisify-es6": "^1.0.1",
"to-title-case": "^1.0.0"
},
"devDependencies": {

@@ -18,15 +27,9 @@ "babel-cli": "^6.9.0",

"babel-preset-stage-0": "^6.5.0",
"babelify": "^7.3.0",
"browserify": "^13.0.1",
"mocha": "^2.5.2",
"mocha-phantomjs": "^4.0.2",
"popsicle": "^6.2.0",
"source-map-support": "^0.4.0"
},
"dependencies": {
"date.js": "^0.3.1",
"is-html": "^1.0.0",
"is-isodate": "0.0.1",
"is-url": "^1.2.1",
"jsdom": "^9.2.0",
"promisify-es6": "^1.0.1",
"to-title-case": "^1.0.0"
}
}

@@ -6,3 +6,5 @@

Works on the server and in the browser!
## Example

@@ -31,3 +33,3 @@

```js
import { scrapeUrl } from 'metascraper'
import { scrapeUrl } from 'metascraper/server'

@@ -42,6 +44,4 @@ const metadata = await scrapeUrl('http://www.bloomberg.com/news/articles/2016-05-24/as-zenefits-stumbles-gusto-goes-head-on-by-selling-insurance')

```js
import { scrapeHtml } from 'metascraper'
import { scrapeHtml } from 'metascraper/server'
const res = fetch('http://www.bloomberg.com/news/articles/2016-05-24/as-zenefits-stumbles-gusto-goes-head-on-by-selling-insurance')
const html = res.body
const metadata = await scrapeHtml(html)

@@ -55,3 +55,3 @@ ```

```js
import { scrapeWindow } from 'metascraper'
import { scrapeWindow } from 'metascraper/browser'

@@ -58,0 +58,0 @@ const metadata = await scrapeWindow(window)

Sorry, the diff of this file is not supported yet

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