LibP2PCore
The core LibP2P Interfaces / Protocols and Abstractions backing the swift-libp2p project
Table of Contents
Overview
LibP2PCore is a repository / dependency that houses the building blocks for swift-libp2p.
Note:
- For more information check out the LibP2P Spec
Install
Include the following dependency in your Package.swift file
let package = Package(
...
dependencies: [
...
.package(name: "LibP2PCore", url: "https://github.com/swift-libp2p/swift-libp2p-core.git", .upToNextMajor(from: "0.0.1"))
],
...
.target(
...
dependencies: [
...
.product(name: "LibP2PCore", package: "swift-libp2p-core"),
]),
...
...
)
Usage
Example
check out the tests for more examples
import LibP2PCore
// You now have access to thing like PeerID, Multiaddr, Connections, Swift-NIO, etc...
API
Not Applicable
Contributing
Contributions are welcomed! This code is very much a proof of concept. I can guarantee you there's a better / safer way to accomplish the same results. Any suggestions, improvements, or even just critques, are welcome!
Let's make this code better together!
Credits
License
MIT © 2022 Breth Inc.