Skip to content
This repository has been archived by the owner on Apr 29, 2024. It is now read-only.

Extend ipfs with custom libp2p behaviours #2

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

cobward
Copy link
Collaborator

@cobward cobward commented Feb 10, 2022

Allow the Ipfs NetworkBehaviour to be extended with a custom behaviour.

A user wishing to build an application on top of IPFS may need to define
custom libp2p behaviours in order to hook into the libp2p swarm events.

This allows a user to define a custom behaviour, which can optionally be
constructed with a reference to the IPFS object.
NetworkBehaviour methods are synchronous and Ipfs methods are all async,
so instead we can pass the event channel to the custom behaviour, which
can be used to submit requests synchronously.
@cobward cobward force-pushed the feat/extend-ipfs-with-custom-libp2p-behaviours branch from 0704e40 to 8feabc0 Compare February 10, 2022 19:24
@cobward cobward requested a review from chunningham February 10, 2022 19:25
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant