is-tcp-on

0.1.2 • Public • Published

is-tcp-on

check whether a tcp server could be connected

installation

npm i is-tcp-on

usage

var isTcpOn = require('is-tcp-on');
isTcpOn({
    port: 80,
    host: '127.0.0.1',
    timeout: 1000 // optional, default is 1000ms
})
.then(function () {
    // tcp server exists
}, function () {
    // can not connect to this tcp server
});

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.2
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.1.2
    1
  • 0.1.1
    0
  • 0.1.0
    1

Package Sidebar

Install

npm i is-tcp-on

Weekly Downloads

2

Version

0.1.2

License

MIT

Last publish

Collaborators

  • undozen