@libp2p/kad-dht 6.1.0 → 7.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3,13 +3,14 @@
3
3
  [![libp2p.io](https://img.shields.io/badge/project-libp2p-yellow.svg?style=flat-square)](http://libp2p.io/)
4
4
  [![Discuss](https://img.shields.io/discourse/https/discuss.libp2p.io/posts.svg?style=flat-square)](https://discuss.libp2p.io)
5
5
  [![codecov](https://img.shields.io/codecov/c/github/libp2p/js-libp2p-kad-dht.svg?style=flat-square)](https://codecov.io/gh/libp2p/js-libp2p-kad-dht)
6
- [![CI](https://img.shields.io/github/workflow/status/libp2p/js-libp2p-interfaces/test%20&%20maybe%20release/master?style=flat-square)](https://github.com/libp2p/js-libp2p-kad-dht/actions/workflows/js-test-and-release.yml)
6
+ [![CI](https://img.shields.io/github/actions/workflow/status/libp2p/js-libp2p-kad-dht/js-test-and-release.yml?branch=master\&style=flat-square)](https://github.com/libp2p/js-libp2p-kad-dht/actions/workflows/js-test-and-release.yml?query=branch%3Amaster)
7
7
 
8
8
  > JavaScript implementation of the Kad-DHT for libp2p
9
9
 
10
10
  ## Table of contents <!-- omit in toc -->
11
11
 
12
12
  - [Install](#install)
13
+ - [Browser `<script>` tag](#browser-script-tag)
13
14
  - [Use in Node.js](#use-in-nodejs)
14
15
  - [API](#api)
15
16
  - [Custom secondary DHT in libp2p](#custom-secondary-dht-in-libp2p)
@@ -17,9 +18,9 @@
17
18
  - [Content Routing](#content-routing)
18
19
  - [Peer Discovery](#peer-discovery)
19
20
  - [Spec](#spec)
20
- - [Contribute](#contribute)
21
+ - [API Docs](#api-docs)
21
22
  - [License](#license)
22
- - [Contribute](#contribute-1)
23
+ - [Contribution](#contribution)
23
24
 
24
25
  ## Install
25
26
 
@@ -27,6 +28,14 @@
27
28
  $ npm i @libp2p/kad-dht
28
29
  ```
29
30
 
31
+ ### Browser `<script>` tag
32
+
33
+ Loading this module through a script tag will make it's exports available as `Libp2pKadDht` in the global namespace.
34
+
35
+ ```html
36
+ <script src="https://unpkg.com/@libp2p/kad-dht/dist/index.min.js"></script>
37
+ ```
38
+
30
39
  ```sh
31
40
  > npm i @libp2p/kad-dht
32
41
  ```
@@ -78,13 +87,9 @@ Note that you may want to supply your own peer discovery function and datastore
78
87
 
79
88
  js-libp2p-kad-dht follows the [libp2p/kad-dht spec](https://github.com/libp2p/specs/tree/master/kad-dht) and implements the algorithms described in the [IPFS DHT documentation](https://docs.ipfs.io/concepts/dht/).
80
89
 
81
- ## Contribute
82
-
83
- Feel free to join in. All welcome. Open an [issue](https://github.com/libp2p/js-libp2p-kad-dht/issues)!
84
-
85
- This repository falls under the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).
90
+ ## API Docs
86
91
 
87
- [![](https://cdn.rawgit.com/jbenet/contribute-ipfs-gif/master/img/contribute.gif)](https://github.com/ipfs/community/blob/master/CONTRIBUTING.md)
92
+ - <https://libp2p.github.io/js-libp2p-kad-dht>
88
93
 
89
94
  ## License
90
95
 
@@ -93,6 +98,6 @@ Licensed under either of
93
98
  - Apache 2.0, ([LICENSE-APACHE](LICENSE-APACHE) / <http://www.apache.org/licenses/LICENSE-2.0>)
94
99
  - MIT ([LICENSE-MIT](LICENSE-MIT) / <http://opensource.org/licenses/MIT>)
95
100
 
96
- ## Contribute
101
+ ## Contribution
97
102
 
98
103
  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.