Ion-searchbar cursor position points to starting of the string inside the searchbar on focus only on ios

Steps to reproduce:

  1. Type any text in the searchbar.
  2. Take the focus out of the searchbar, so that the keyboard dismisses
  3. Again tap inside the searchbar, now the cursor position points to the starting of the already typed string. (Happens randomly, so try this for 4-5 times)

Ionic Info:

Ionic:

ionic (Ionic CLI) : 4.12.0 (/usr/local/lib/node_modules/ionic)
Ionic Framework : @ionic/angular 4.11.10
@angular-devkit/build-angular : 0.13.9
@angular-devkit/schematics : 7.2.4
@angular/cli : 7.3.9
@ionic/angular-toolkit : 1.4.1

Cordova:

cordova (Cordova CLI) : 8.1.0
Cordova Platforms : android 6.4.0, ios 5.1.1
Cordova Plugins : cordova-plugin-ionic-crop 0.0.1, cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 2.5.3, (and 32 other plugins)

System:

ios-sim : 8.0.2
NodeJS : v10.18.1 (/usr/local/bin/node)
npm : 6.4.1
OS : macOS Mojave
Xcode : Xcode 11.3.1 Build version 11C504

Please provide a solution for this.