🌐 Makes Internet connectivity detection more robust by detecting Wi-Fi networks without Internet access.
checkWhenApplicationDidBecomeActive
flag which when enabled will check connectivity status when an app returns from the background.pollWhileOfflineOnly
flag which ensures that Connectivity only polls after recording an unsuccessful connection result. Following a successful result polling will cease.checkConnectivity
is now offloaded to internalQueue
immediately.NotReachable
) where using the .systemConfiguration
framework option. In this instance, Connectivity now uses NWPathMonitor
as a fallback on iOS 12+ even where .systemConfiguration
is the selected option.Provides the ability to switch between Reachability and the Network framework (on iOS 12+) using the new framework property on the Connectivity object.
Refactored code into smaller reusable functions to eliminate code duplication and improve maintainability.
Updated for Xcode 10 and Swift 4.2.
Fixed an issue whereby the callback could be invoked more frequently than necessary if using the polling option.
Adds a sample application to demonstrate how to use Connectivity. Additionally contains improvements to code structure and an early exit mechanism such that once the required number of successful connectivity checks has been met any pending checks will be cancelled as they will no longer affect the result.
Connectivity is a framework which improves on Reachability by allowing developers to detect whether true Internet connectivity is available or whether a captive portal is blocking Internet traffic. This blog post provides further details.