strong-wait-till-listening

2019-02-12 admin

strong-wait-till-listening是什么

什么是strong-wait-till-listening,Wait until a TCP server is listening on the given port

strong-wait-till-listening使用教程帮助文档

strong-wait-till-listening

This module provides a utility function to wait until there is a TCP server listening on a given port.

Installation

$ npm install strong-wait-till-listening

Usage

var waitTillListening = require('strong-wait-till-listening');

waitTillListening(
  {
    // optional, defaults to 'localhost'
    host: 'localhost',
    port: 3000,
    timeoutInMs: 20000,
    // optional, defaults to 50
    pollingIntervalInMs: 50
  },
  function waitCallback(err) {
  }
);

本站文章除注明转载外,均为本站原创或编译。欢迎任何形式的转载,但请务必注明出处。

转载请注明:文章转载自 JavaScript中文网 [https://www.javascriptcn.com]

本文地址:https://www.javascriptcn.com/read-53582.html

文章标题:strong-wait-till-listening

回到顶部