When iOS Autofill doesn’t work on Angular or ionic framework

Unlike Chrome or Android’s autofill, iOS autofill doesn’t touch userId and password fields. Any events like onChange or onKeydown are not called. Therefore, ngModel is also not updated. Oh my god it’s so frustrating… I have rejected from AppstoreConnect for this reason.

To avoid this problem, there are several solutions.

  1. Don’t publish to Appstore. (Best)
  2. Wait until iOS triggers all Autofill fields (Good)
  3. Avoid Autofill (change input type=”password” to “text”)
  4. Directly read the input fields (nativeElement)

I prefer the first or second one but that was not possible, so I had applied the third one then I passed the App review. But I felt sorry to users who like to use Autofill, not even on iOS but also on Android, Chrome, or anything else. So I applied the last one.

You know I really like my new iPhone 11 and I think it is so elegant. But I don’t think iOS development is not like that. When I autofill on the userId field, it triggers on the userId field’s event only. When I autofill on the password field, it triggers on the password’s event only. It doesn’t triggers both fields! Oh my apple please don’t…

reference: https://stackoverflow.com/questions/53555114/ios-autofill-data-in-login-forms-is-empty-in-cordova-application-using-angular

Loading

Published
Categorized as xacdo

By xacdo

Kyungwoo Hyun

Leave a comment

Your email address will not be published. Required fields are marked *