Clear() is not clearing the prepopulated text box in ios

We have been stuck on this for few days now. Appreciate your help.

WebElement element = driver.findElement(…);
element.sendKeys(“text to send”);

This is not clearing the existing text in the text box and clicking anywhere in middle or end of the existing text and typing the keys we are sending in. I am seeing this only on ios and not on Android.

Also tried sending CONTROL+“a” and DELETE keys before sending the text. That didnt work as well. We are using appium javaclient 3.0.


Can you try using setValue() method which will by default clear any pre existing text?
Disclaimer- This is just a workaround