Skip to content

Commit b4f88e7

Browse files
authored
fix: publish tsdocs for this module (libp2p#236)
Publishes docs to gh-pages with links to external modules
1 parent 01fe00f commit b4f88e7

File tree

3 files changed

+10
-53
lines changed

3 files changed

+10
-53
lines changed

.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,5 @@ node_modules
22
package-lock.json
33
coverage
44
.nyc_output
5-
docs
6-
5+
.docs
76
dist

README.md

Lines changed: 5 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -5,33 +5,22 @@
55
[![codecov](https://img.shields.io/codecov/c/github/libp2p/js-libp2p-tcp.svg?style=flat-square)](https://codecov.io/gh/libp2p/js-libp2p-tcp)
66
[![CI](https://img.shields.io/github/workflow/status/libp2p/js-libp2p-tcp/test%20&%20maybe%20release/master?style=flat-square)](https://github.com/libp2p/js-libp2p-tcp/actions/workflows/js-test-and-release.yml)
77

8-
> Node.js implementation of the TCP module that libp2p uses, which implements the interface-connection and interface-transport interfaces
8+
> A TCP transport for libp2p
99
1010
## Table of contents <!-- omit in toc -->
1111

1212
- [Install](#install)
1313
- [Usage](#usage)
14-
- [API](#api)
15-
- [Transport](#transport)
16-
- [Connection](#connection)
17-
- [Contribute](#contribute)
18-
- [Contribute](#contribute-1)
14+
- [API Docs](#api-docs)
1915
- [License](#license)
20-
- [Contribute](#contribute-2)
16+
- [Contribute](#contribute)
2117

2218
## Install
2319

2420
```console
2521
$ npm i @libp2p/tcp
2622
```
2723

28-
[![](https://raw.githubusercontent.com/libp2p/js-libp2p-interfaces/master/src/transport/img/badge.png)](https://github.com/libp2p/js-libp2p-interfaces/tree/master/src/transport)
29-
[![](https://raw.githubusercontent.com/libp2p/js-libp2p-interfaces/master/src/connection/img/badge.png)](https://github.com/libp2p/js-libp2p-interfaces/tree/master/src/connection)
30-
31-
```sh
32-
> npm install @libp2p/tcp
33-
```
34-
3524
## Usage
3625

3726
```js
@@ -82,41 +71,9 @@ new connection opened
8271
Value: hello World!
8372
```
8473

85-
## API
86-
87-
### Transport
88-
89-
[![](https://raw.githubusercontent.com/libp2p/js-libp2p-interfaces/master/packages/libp2p-interfaces/src/transport/img/badge.png)](https://github.com/libp2p/js-libp2p-interfaces/tree/master/packages/libp2p-interfaces/src/transport)
90-
91-
`@libp2p/tcp` accepts TCP addresses as both IPFS and non IPFS encapsulated addresses, i.e:
92-
93-
`/ip4/127.0.0.1/tcp/4001`
94-
`/ip4/127.0.0.1/tcp/4001/ipfs/QmHash`
95-
96-
(both for dialing and listening)
97-
98-
### Connection
99-
100-
[![](https://raw.githubusercontent.com/libp2p/js-libp2p-interfaces/master/packages/libp2p-interfaces/src/connection/img/badge.png)](https://github.com/libp2p/js-libp2p-interfaces/tree/master/packages/libp2p-interfaces/src/connection)
101-
102-
## Contribute
103-
104-
Contributions are welcome! The libp2p implementation in JavaScript is a work in progress. As such, there's a few things you can do right now to help out:
105-
106-
- [Check out the existing issues](//github.com/libp2p/js-libp2p-tcp/issues).
107-
- **Perform code reviews**.
108-
- **Add tests**. There can never be enough tests.
109-
110-
Please be aware that all interactions related to libp2p are subject to the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
111-
112-
Small note: If editing the README, please conform to the [standard-readme](https://github.com/RichardLitt/standard-readme) specification.
113-
114-
## Contribute
115-
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:
74+
## API Docs
11775

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.
76+
- <https://libp2p.github.io/js-libp2p-tcp>
12077

12178
## License
12279

package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@libp2p/tcp",
33
"version": "6.0.6",
4-
"description": "Node.js implementation of the TCP module that libp2p uses, which implements the interface-connection and interface-transport interfaces",
4+
"description": "A TCP transport for libp2p",
55
"license": "Apache-2.0 OR MIT",
66
"homepage": "https://github.com/libp2p/js-libp2p-tcp#readme",
77
"repository": {
@@ -28,7 +28,7 @@
2828
"types": "./dist/src/index.d.ts",
2929
"files": [
3030
"src",
31-
"dist/src",
31+
"dist",
3232
"!dist/test",
3333
"!**/*.tsbuildinfo"
3434
],
@@ -134,6 +134,7 @@
134134
"lint": "aegir lint",
135135
"dep-check": "aegir dep-check",
136136
"build": "aegir build",
137+
"docs": "aegir docs",
137138
"test": "aegir test -t node -t electron-main",
138139
"test:node": "aegir test -t node --cov",
139140
"test:electron-main": "aegir test -t electron-main",
@@ -154,7 +155,7 @@
154155
"devDependencies": {
155156
"@libp2p/interface-mocks": "^8.0.1",
156157
"@libp2p/interface-transport-compliance-tests": "^3.0.0",
157-
"aegir": "^37.5.3",
158+
"aegir": "^37.7.3",
158159
"it-all": "^2.0.0",
159160
"it-pipe": "^2.0.3",
160161
"p-defer": "^4.0.0",

0 commit comments

Comments
 (0)