I had the wifi connectivity issues with my iPhone 5S - it would disconnect randomly from wifi and switch to cellular data network at places, where computers and other phones had no issues. The phone would not switch back to wifi without manually turning wifi off and on, search wifi networks or locking and unlocking the screen. I noticed the problem after installing iOs 8.0. I did not install ios 8.0.1, but installed 8.0.2 that did not make much difference. Then I got the new wifi ruouter and installed the 8.1 that made the phone more stable with wifi, but the problem did not go away. Since I had my phone still under warranty, I took it do Apple dealer. After testing they told, that the wifi module is faulty in 2.4 GHz bandwidth, and replaced the phone under warranty.
So today I have been able to test my replaced 5S with three versions of iOs- 7, that it came with, then 8.1, and last the 8.1.1 that was released a week ago. The phone was very stable with wifi with iOs 7, but with both iOs 8.1 and 8.1.1 I have had a couple of occasions, where the phone has switched off the wifi to cellular data network and has not switched back automatically. I have had to switch wifi on/off or choose to connect manually.
It seems that the 5S has weaker wifi reception, than the old 3GS that I had before, as with 3GS I had never such wifi connection issues at home and at my workplace as with the 5S. Also seems, that all versions of iOs 8 so far seem to have trouble keeping the steady wifi connection. But still, if you have wifi issues with your phone still under warranty, and you have an Apple dealer in your area, you should get your phone tested, to rule out the hardware issues. With those couple of dropouts that I have had in two weeks, I can say that the phone is very much usable again.