2015-09-20 16:19:13 +01:00
2015-09-20 16:18:34 +01:00
2015-07-23 14:05:43 -07:00
2015-08-25 11:00:19 +01:00
2015-07-23 14:05:43 -07:00
2015-09-20 16:19:13 +01:00
2015-09-20 16:18:34 +01:00

node-libp2p

[ Build Status](https://travis-ci.org/diasdavid/node-libp2p) Dependency Status js-standard-style

Node.js implementation of libp2p

Interface

This is a work in progress, interface might change at anytime

libp2p expects a Record Store interface, a swarm and one or more Peer Routers that implement the Peer Routing, the goal is to keep simplicity and plugability while the remaining modules execute the heavy lifting.

Setting everything up

var libp2p = require('libp2p')

Dialing and listening

libp2p.swarm.dialStream(peerInfo, protocol, options, function (err, stream) {}) libp2p.swarm.handleProtocol(protocol, options, handlerFunction)

Using Peer Routing

libp2p.routing.findPeers(key, function (err, peerInfos) {})

Using Records

libp2p.record.get(key, function (err, records) {}) libp2p.record.store(key, record)

Stats

Notes

Img for ref (till we get a better graph)

Description
No description provided
Readme 23 MiB
Languages
TypeScript 100%