Sample project leveraging Apple's newest WorkoutKit SDK. You will need Xcode 15.0 Beta 6 (15A5219j) and iOS 17 beta simulator to run this project.
Project and SDK still in Beta and subject to changes.
To properly utilize this project you need to select an iOS simulator with a paired watchOS simulator (iPhone 14 + Watch Ultra
for example). Build and run so iOS simulator is fired up and then go to Simulator > File > Open Simulator and select your paired up watchOS simulator. Both should be paired up. If not, then workout previews will not work.
Known issues:
- Apple has changed how
CustomWorkout
s are initiated, going away from a throwing initializer. After this change, the way I have initialy set up this project will cause crashes when trying to add anyWorkoutStep
with unsupported goal for a particularActivityType
instead of the old alert when pressing to present a preview (i.e. withActivityType = .other
, if you would try to add aWorkoutStep
with adistance
goal, app will crash instantly because ofunsuportedGoal
)