I am wondering how we could check if the new iOS 10 API UIFeebackGenerator
is available on the current device. There are some more things we would need to check
You know your device support Haptic vibration effect or not with below code,
UIDevice.currentDevice().valueForKey("_feedbackSupportLevel");
These methods seem to return:
0 = Taptic not available
1 = First generation (tested on an iPhone 6s) ... which does NOT support UINotificationFeedbackGenerator, etc.
it returns 2 for devices with haptic feedback - iPhone 7/7+ or higher so, you can easily use this to generate Haptic feedback