Awesome
<p align="center"> <a href="https://libp2p.io"> <img width="250" src="https://github.com/libp2p/js-libp2p/blob/main/img/libp2p.png?raw=true" alt="libp2p hex logo" /> </a> </p> <h3 align="center">A collection of js-libp2p examples</h3> <p align="center"> <img src="https://raw.githubusercontent.com/jlord/forkngo/gh-pages/badges/cobalt.png" width="200"> <br> <a href="https://github.com/libp2p/js-libp2p/tree/master/doc">Explore the docs</a> · <a href="https://github.com/libp2p/js-libp2p-examples/issues">Report Bug</a> · <a href="https://github.com/libp2p/js-libp2p-examples/issues">Request Feature/Example</a> </p>Table of Contents <!-- omit in toc -->
About The Project
- Read the js-libp2p documentation
- Check out the js-libp2p API docs
- Check out the general libp2p documentation for tips, how-tos and more
- Read the libp2p specs
- See https://blog.libp2p.io for news and more
- Head over to https://proto.school to take interactive tutorials that cover core libp2p APIs
- Need help? Visit the discussion board: https://github.com/libp2p/js-libp2p/discussions
Getting Started
Feel free to jump directly into the examples, however going through the following sections will help build context and background knowledge.
Prerequisites
Make sure you have installed all of the following prerequisites on your development machine:
- Git - Download & Install Git. OSX and Linux machines typically have this already installed.
- Node.js - Download & Install Node.js and the npm package manager.
Understanding how libp2p works
- Circuit Relay - configuring Circuit Relay connections
- Connection Encryption - how to encrypt connection between libp2p nodes
- Delegated routing - how to offload network operations and queries onto more capable nodes
- Discovery mechanisms - how libp2p discovers other peers on the network
- Custom protocols - how to create a custom protocol for your application
- Transports - how to connect peers together via different transports
- WebRTC - a special transport for connecting browsers together
Other examples
These are demo apps or examples that showcase specific modules or services:
- Chat - a simple chat app
- Browser Pub/Sub - Using Pub/Sub between browsers
There is also universal connectivity demo that shows of how many different libp2p implementations can be connected together.
Contribute
See CONTRIBUTING.md.
License
Licensed under either of
- Apache 2.0, (LICENSE-APACHE / http://www.apache.org/licenses/LICENSE-2.0)
- MIT (LICENSE-MIT / http://opensource.org/licenses/MIT)