A libp2p transport based on WebTransport.
⚠️ Note This WebTransport implementation currently only allows dialing to other nodes. It does not yet allow listening for incoming dials. This feature requires QUIC support to land in Node JS first. QUIC support in Node JS is actively being worked on. You can keep an eye on the progress by watching the related issues on the Node JS issue tracker
⚠️ Note
This WebTransport implementation currently only allows dialing to other nodes. It does not yet allow listening for incoming dials. This feature requires QUIC support to land in Node JS first.
QUIC support in Node JS is actively being worked on. You can keep an eye on the progress by watching the related issues on the Node JS issue tracker
import { createLibp2p } from 'libp2p'import { webTransport } from '@libp2p/webtransport'import { noise } from '@chainsafe/libp2p-noise'const node = await createLibp2p({ transports: [ webTransport() ], connectionEncrypters: [ noise() ]}) Copy
import { createLibp2p } from 'libp2p'import { webTransport } from '@libp2p/webtransport'import { noise } from '@chainsafe/libp2p-noise'const node = await createLibp2p({ transports: [ webTransport() ], connectionEncrypters: [ noise() ]})
A libp2p transport based on WebTransport.
Example