chore: auto relay configuration example with noise (#828)

This commit is contained in:
Vasco Santos 2020-12-09 16:27:42 +01:00 committed by Vasco Santos
parent f7e1426b9e
commit 7809e6444e

View File

@ -445,13 +445,13 @@ const node = await Libp2p.create({
const Libp2p = require('libp2p')
const TCP = require('libp2p-tcp')
const MPLEX = require('libp2p-mplex')
const SECIO = require('libp2p-secio')
const { NOISE } = require('libp2p-noise')
const node = await Libp2p.create({
modules: {
transport: [TCP],
streamMuxer: [MPLEX],
connEncryption: [SECIO]
connEncryption: [NOISE]
},
config: {
relay: { // Circuit Relay options (this config is part of libp2p core configurations)