When connecting to go-IPFS from a webworker, the stream opened by
the ping protocol is never closed.
The change here uses `take` to only receive one buffer from the
remote node before closing the stream.
* docs: redirect to the npm docs for latest release
* Apply suggestions from code review
Co-Authored-By: Jacob Heun <jacobheun@gmail.com>
Co-authored-by: Jacob Heun <jacobheun@gmail.com>
* refactor: examples-browser
* chore: add information to use signalling server
* chore: apply suggestions from code review
Co-Authored-By: Jacob Heun <jacobheun@gmail.com>
* chore: update deps
* docs: refactor libp2p browser example
* docs(examples): add back websockets and boostrap nodes
docs(examples): redo the browser readme
* fix: handle edge case of connections closing early
* chore: fix lint
* chore: update example deps and readme
* chore: update webrtc-star
* chore: apply suggestions from code review
Co-Authored-By: Alan Shaw <alan.shaw@protocol.ai>
Co-authored-by: Jacob Heun <jacobheun@gmail.com>
Co-authored-by: Alan Shaw <alan.shaw@protocol.ai>
* docs: getting started
* docs: review getting started (#520)
* doc: initial review of getting started
Co-Authored-By: Vasco Santos <vasco.santos@moxy.studio>
* chore: move multiplexing to basic setup
* chore: add read more cta
* chore: apply suggestions from code review
Co-Authored-By: Jacob Heun <jacobheun@gmail.com>
* chore: just configure multiplexer
* chore: apply suggestions from code review
Co-Authored-By: Jacob Heun <jacobheun@gmail.com>
* chore: just use websockets and changed dht module introduction
* chore: add reference for events in the API doc
* docs: simplify getting started guide and clean up language
* chore: apply suggestions from code review
Co-Authored-By: Alan Shaw <alan.shaw@protocol.ai>
* docs(fix): address review comments
Co-authored-by: Jacob Heun <jacobheun@gmail.com>
Co-authored-by: Alan Shaw <alan.shaw@protocol.ai>
* fix: upgrader should not need muxers
* chore: address review
* chore: apply suggestions from code review
Co-Authored-By: Jacob Heun <jacobheun@gmail.com>
* docs: fix spelling in api
* fix: dont create peerstore twice
* feat: add support for dial coalescing
* doc(fix): add setPeerValue to API TOC
* docs: add more jsdocs to dialer
* chore: remove old comment
* fix: ensure connections are closed
* fix: registrar.getConnections returns first open conn
* fix: directly set the closed status
* chore: remove unneeded log
* refactor: peerStore.put takes an options object
* refactor: initial refactor of the connection manager
* fix: start/stop issues
* fix: add tests and resolve pruning issues
* chore: fix lint
* test: move conn manager tests to node only for now
* chore: apply suggestions from code review
Co-Authored-By: Vasco Santos <vasco.santos@moxy.studio>
* fix: assert min max connection options
* test: fix assertion check for browser
* docs: add api and config docs for conn manager
* feat: discovery modules from transports should be added
* chore: apply suggestions from code review
Co-Authored-By: Jacob Heun <jacobheun@gmail.com>
* chore: address review
* chore: apply suggestions from code review
Co-Authored-By: Jacob Heun <jacobheun@gmail.com>
* docs: add initial notes on stats
* feat: initial refactor of stats to metrics
* feat: add support for placeholder metrics
This is helpful for tracking metrics prior to knowing the remote peers id
* fix: add metrics tests and fix issues
* fix: always clear the dial timeout timer
* docs: add metrics to api doc
* chore: apply suggestions from code review
Co-Authored-By: Vasco Santos <vasco.santos@moxy.studio>
* docs: update metrics docs
* fix: call metrics.onDisconnect
* docs(config): add example headers so they appear in the TOC
* docs(config): add metrics configuration
* docs(relay): fix relay configuration docs