Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix code snippets to achieve working libp2p-host example #2766

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

apenzk
Copy link
Contributor

@apenzk apenzk commented Apr 12, 2024

This PR updates the readme of examples/libp2p-host/.

In the current form the code snippets of the readme do not work and lead to errors. The code snippets now align with the example code.

@apenzk apenzk mentioned this pull request Apr 12, 2024
@MarcoPolo
Copy link
Contributor

Is there value in having this code duplicated in multiple places? README.md and host.go in the example? Did you find it helpful when you read through this?

@apenzk
Copy link
Contributor Author

apenzk commented May 8, 2024

For consistency I would argue against duplication. As for exactly this reason errors were present. Also the readme code is not tested.

In contrast, personally I learnt something from it that I would otherwise not. So for me it was valuable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants