1.1.3 • Published 1 year ago

test-holesail-server v1.1.3

Weekly downloads
-
License
GNU GPL v3
Repository
github
Last release
1 year ago

holesail-server

Join our Discord Support Server

Create and announce your server on the HyperDHT P2P protocol.

Installation

npm i holesail-server --save-dev

Usage

Require a module

const DHT = require('holesail-server')

Create instance of the holesailServer class

const server =  new DHT();

Start DHT and get the public key

server.serve(5000, '127.0.0.1', () => {
  console.log('Server 1 started');
});

console.log('Server public key:', server.getPublicKey());

Destroy the DHT server

server.destroy();