Your first package: PawWalkKit

Extracting the shared core

The first split is usually the easiest: pull out the code every feature needs β€” Models (Walker, Booking, WalkRecord) and APIClient β€” into a package called PawWalkKit. It has no UI, no SwiftUI imports, just types and networking. Every feature package and the app itself will depend on it, so it has to depend on nothing feature-specific in return.

A package's products array is its public face β€” what a Package.swift in a different package can request with .product(name:package:). A package's targets array is where the code actually lives; a product just points at one or more targets and says "these are what I'm exposing." The app target then adds PawWalkKit as a dependency and imports it like any other module: import PawWalkKit.