|
1 |
| -# js-libp2p-tcp <!-- omit in toc --> |
| 1 | +# @libp2p/tcp <!-- omit in toc --> |
2 | 2 |
|
3 |
| -[](http://protocol.ai) |
4 |
| -[](http://libp2p.io/) |
5 |
| -[](http://webchat.freenode.net/?channels=%23libp2p) |
6 |
| -[](https://discuss.libp2p.io) |
7 |
| -[](https://codecov.io/gh/libp2p/js-libp2p-tcp) |
8 |
| -[](https://github.com/libp2p/js-libp2p-tcp/actions/workflows/js-test-and-release.yml) |
9 |
| -[](https://david-dm.org/libp2p/js-libp2p-tcp) |
10 |
| -[](https://github.com/feross/standard) |
| 3 | +[](http://libp2p.io/) |
| 4 | +[](http://webchat.freenode.net/?channels=%23libp2p) |
| 5 | +[](https://discuss.libp2p.io) |
| 6 | +[](https://codecov.io/gh/libp2p/js-libp2p-tcp) |
| 7 | +[](https://github.com/libp2p/js-libp2p-tcp/actions/workflows/js-test-and-release.yml) |
11 | 8 |
|
12 |
| -[](https://github.com/libp2p/js-libp2p-interfaces/tree/master/src/transport) |
13 |
| -[](https://github.com/libp2p/js-libp2p-interfaces/tree/master/src/connection) |
| 9 | +> Node.js implementation of the TCP module that libp2p uses, which implements the interface-connection and interface-transport interfaces |
14 | 10 |
|
15 |
| -> JavaScript implementation of the TCP module for libp2p. It exposes the [interface-transport](https://github.com/libp2p/js-libp2p-interfaces/tree/master/packages/libp2p-interfaces/src/transport) for dial/listen. `libp2p-tcp` is a very thin shim that adds support for dialing to a `multiaddr`. This small shim will enable libp2p to use other transports. |
16 |
| -
|
17 |
| -## Table of Contents <!-- omit in toc --> |
| 11 | +## Table of contents <!-- omit in toc --> |
18 | 12 |
|
19 | 13 | - [Install](#install)
|
20 |
| - - [npm](#npm) |
21 | 14 | - [Usage](#usage)
|
22 | 15 | - [API](#api)
|
23 | 16 | - [Transport](#transport)
|
24 | 17 | - [Connection](#connection)
|
25 | 18 | - [Contribute](#contribute)
|
26 | 19 | - [Contribute](#contribute-1)
|
27 | 20 | - [License](#license)
|
28 |
| - - [Contribution](#contribution) |
| 21 | +- [Contribution](#contribution) |
29 | 22 |
|
30 | 23 | ## Install
|
31 | 24 |
|
32 |
| -### npm |
| 25 | +```console |
| 26 | +$ npm i @libp2p/tcp |
| 27 | +``` |
| 28 | + |
| 29 | +[](https://github.com/libp2p/js-libp2p-interfaces/tree/master/src/transport) |
| 30 | +[](https://github.com/libp2p/js-libp2p-interfaces/tree/master/src/connection) |
33 | 31 |
|
34 | 32 | ```sh
|
35 | 33 | > npm install @libp2p/tcp
|
@@ -117,16 +115,16 @@ Small note: If editing the README, please conform to the [standard-readme](https
|
117 | 115 |
|
118 | 116 | The libp2p implementation in JavaScript is a work in progress. As such, there are a few things you can do right now to help out:
|
119 | 117 |
|
120 |
| - - Go through the modules and **check out existing issues**. This is especially useful for modules in active development. Some knowledge of IPFS/libp2p may be required, as well as the infrastructure behind it - for instance, you may need to read up on p2p and more complex operations like muxing to be able to help technically. |
121 |
| - - **Perform code reviews**. More eyes will help a) speed the project along b) ensure quality and c) reduce possible future bugs. |
| 118 | +- Go through the modules and **check out existing issues**. This is especially useful for modules in active development. Some knowledge of IPFS/libp2p may be required, as well as the infrastructure behind it - for instance, you may need to read up on p2p and more complex operations like muxing to be able to help technically. |
| 119 | +- **Perform code reviews**. More eyes will help a) speed the project along b) ensure quality and c) reduce possible future bugs. |
122 | 120 |
|
123 | 121 | ## License
|
124 | 122 |
|
125 | 123 | Licensed under either of
|
126 | 124 |
|
127 |
| - * Apache 2.0, ([LICENSE-APACHE](LICENSE-APACHE) / http://www.apache.org/licenses/LICENSE-2.0) |
128 |
| - * MIT ([LICENSE-MIT](LICENSE-MIT) / http://opensource.org/licenses/MIT) |
| 125 | +- Apache 2.0, ([LICENSE-APACHE](LICENSE-APACHE) / <http://www.apache.org/licenses/LICENSE-2.0>) |
| 126 | +- MIT ([LICENSE-MIT](LICENSE-MIT) / <http://opensource.org/licenses/MIT>) |
129 | 127 |
|
130 |
| -### Contribution |
| 128 | +## Contribution |
131 | 129 |
|
132 | 130 | Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
|
0 commit comments