Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,11 @@ import PackageDescription

let package = Package(
name: "AsyncLocationKit",
platforms: [.iOS("13.0")],
platforms: [
.iOS("13.0"),
.macOS(.v12)
],

products: [
.library(
name: "AsyncLocationKit",
Expand Down
5 changes: 5 additions & 0 deletions Sources/AsyncLocationKit/AsyncLocationManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,9 @@ public final class AsyncLocationManager {
locationManager.stopMonitoringVisits()
}

#if os(iOS)

@available(iOS 13, *)
public func startUpdatingHeading() async -> HeadingMonitorStream {
let performer = HeadingMonitorPerformer()
return HeadingMonitorStream { stream in
Expand All @@ -147,6 +150,8 @@ public final class AsyncLocationManager {
locationManager.stopUpdatingHeading()
}

#endif

public func startRangingBeacons(satisfying: CLBeaconIdentityConstraint) async -> BeaconsRangingStream {
let performer = BeaconsRangePerformer(satisfying: satisfying)
return BeaconsRangingStream { stream in
Expand Down