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

drudgereport

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

drudgereport

Polls the DrudgeReport.com website and tracks the links

  • 1.1.2
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Synopsis

Used by FortunesRocks.me LLC for news monitoring

Code Example

// 
// ==> Create a DrudgeReport object
//
    var dr = new DrudgeReport(); 
//
// ==> Create a callback function.  DR will call this each time it has new
// ==> articles, once you pass it to DR. 
//
    var myStream = (articles:DrudgeArticle[]) => {
        console.log("Got a new set of articles",articles.length);
        processStream(articles);
    }

    dr.stream(myStream);

//
// ==> done!
//


Motivation

DrudgeReport is one of the most infulential news based websites in the world. Monirtoring the feed is crtical to news senstive markets.

Installation

npm install --save drudgereport

API Reference

To set the loglevel to debug..

dr.setLogLevel("info"); [debug,info,warn,error] are all legit values;

To set poll rate (default if 15 minutes);

dr.setPollInterval = 15 * 60;  (this is 15 minutes, value is seconds)
//
// ==> Object model
//

export class DrudgeArticle {
    html: string;
    time: Date;
    location: string;
    index: number;
    source: string;
    href: string;
    latest: Date;
}

Tests

There is a testDrudge.ts/js included in the package to test the function.

Contributors

FortunesRocks.me LLC contact me there if you have questions; npms + "the little a rolled in a blanket"+fortunesrocks.me

License

ISC

Keywords

FAQs

Package last updated on 16 Nov 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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