Project Setup (iOS)

Recommended project configuration for a stable LiteP2P experience on iOS.

Swift Package Manager

In Xcode: File → Add Packages, then enter:

https://github.com/litep2p/litep2p-ios.git

Info.plist permissions

<key>NSLocalNetworkUsageDescription</key>
<string>LiteP2P uses the local network to discover nearby peers.</string>

<key>NSBonjourServices</key>
<array>
  <string>_litep2p._tcp</string>
  <string>_litep2p._udp</string>
</array>

App structure

  • Create one LiteP2P instance per app process.
  • Connect/disconnect with app lifecycle.
  • Store state locally; treat incoming data as untrusted.