JSPM

heartsuite-client

1.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 3
  • Score
    100M100P100Q37013F
  • License MIT

Heartsuite Client that send heartbeats to a Heartsuite server

Package Exports

  • heartsuite-client

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (heartsuite-client) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

heartsuite-client

heartsuite-client is the client that sends heartbeat to a heartsuite-server

Usage

const HeartSuiteClient = require('heartsuite-client');
const server = "localhost"; //Server IP
const port = 23232; //Server port
const interval = 3000; //Heartbeat interval (ms)
const data = {}; //Additional data to be send to the server

let client = new HeartSuiteClient(server, port, interval, data);

client.on('beat', function(time){
  console.log(`Beat sent : ${time}`);
});

Issues

  • Feature request : tag [Feature]
  • Issue : please describe the problem and give steps to reproduce

Pull request

  • Use 2-space tabs