mirror of
https://github.com/fluencelabs/js-libp2p
synced 2025-05-29 02:11:18 +00:00
30 lines
767 B
Markdown
30 lines
767 B
Markdown
ipfs-swarm Node.js implementation
|
|
=================================
|
|
|
|
[](http://ipn.io) [](http://webchat.freenode.net/?channels=%23ipfs)
|
|
|
|
> IPFS swarm implementation in Node.js
|
|
|
|
# Description
|
|
|
|
ipfs-swarm is an abstraction for the network layer on IPFS. It offers an API to open streams between peers on a specific protocol.
|
|
|
|
Ref link (still a WiP) - https://github.com/diasdavid/specs/blob/protocol-spec/protocol/layers.md#network-layer
|
|
|
|
# Usage
|
|
|
|
## API calls
|
|
|
|
.openStream
|
|
.registerHandle
|
|
|
|
## Events emmited
|
|
|
|
.on('error')
|
|
|
|
.on('connection')
|
|
.on('connection-unknown')
|
|
|
|
.on('stream')
|
|
.on('stream-unknown')
|