h5

0.0.5 • Public • Published

h5js

Distributed computing with JSON.

Checkout example.js and cloud.js in examples directory.

var h5 = require('h5');
 
require('./functions.js');
 
var example =
  h5.action('http.request', { url: 'http://www.imdb.com/title/tt0110912/' }).
     action('html.extract', { selectors: { title: 'h1.header > span[itemprop="name"]', year: 'h1.header > span > a' } });
 
example.
  run().
  then(function(result) {
    console.log(result);
  }, function(err) {
    console.log('Error:', err);
  });

Saving action and running in cloud

h5.cloud.set('http://127.0.0.1:6090/');
 
example.
  save().
  then(function() {
    example.
      run({url: 'http://www.imdb.com/title/tt0137523/'}, true).
      then(function(result) {
        console.log(result);
      }, function(err) {
        console.log('Error:', err);
      });
  });

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.5
    51
    • latest

Version History

Package Sidebar

Install

npm i h5

Weekly Downloads

44

Version

0.0.5

License

none

Last publish

Collaborators

  • crackcomm