Get keyboardTypein the delegate methods an InputView instead of ViewDidLoad. Because you cannot get the type of keyboard until the keyboard is fully represented and the input object is activated.
- (void)textWillChange:(id<UITextInput>)textInput {
NSLog(@"TextInputMode: %ld", self.textDocumentProxy.keyboardType);
}
OR
- (void)textDidChange:(id<UITextInput>)textInput {
NSLog(@"TextInputMode: %ld", self.textDocumentProxy.keyboardType);
}
source
share