hltv-match

1.0.0 • Public • Published

hltv-match

Parse HLTV match page.

Example

var hltvMatch = require('hltv-match');
 
var url = 'http://www.hltv.org/?pageid=188&matchid=18745&eventid=0&gameid=2';
 
hltvMatch(url, function(error, data) {
  if (error) {
    throw error;
  }
 
  console.log(data);
  // => {
  // =>   map: 'mirage',
  // =>   event: 'ESEA Invite Season 17 Global Finals',
  // =>   homeScore: 16,
  // =>   awayScore: 12,
  // =>   home: 'mousesports',
  // =>   away: 'Cloud9'
  // => }
});

Installation

$ npm install hltv-match

API

var hltvMatch = require('hltv-match');

hltvMatch(url, callback)

Parses the match at String url and calls callback(error, data), where error is any Error encounted and data is an Object populated with the parsed data.

Readme

Keywords

Package Sidebar

Install

npm i hltv-match

Weekly Downloads

0

Version

1.0.0

License

MIT

Last publish

Collaborators

  • kenan