I want to use Xcode 9 to add iOS 11 code to my project while keeping the option to compile the project with Xcode 8 which only supports iOS 10.
In Objective-C I can do t
This is the solution suggested by Apple:
if #available(iOS 11.0, *) { // iOS 11 specific stuff here } else { // non iOS 11 stuff here }
Please refer to this resource (watch video on mark 6:50 for more details)