Still a poor experience developing with Android device compared to iOS device

#1

When I develop with Expo I have the iOS simulator, an iPhone, an iPad, and a Samsung Android tablet handy, talking over the LAN (wifi). I thought I’d mention some of the ways in which the Android development experience is still clunky, especially when it comes to Live Reload and the edit-compile-run cycle, at least compared with the incredible almost instant reload cycle on iOS, to see if others are experiencing the same things and if these issues are known and being worked on.

Flaky and error-prone Live Reload: When I save my code, sometimes the Android tablet does nothing. Sometimes it appears to do nothing for several seconds or longer, with no visual feedback, and then suddenly refreshes. I’m not sure what the upper bound is on refresh time, i.e. how long I have to wait to be sure it is not refreshing. The worst part is, if I do a manual refresh while an automatic refresh is in progress, Expo breaks and I have to quit and relaunch it. One failure mode is Expo shows a blue screen (an error message with two icons, refresh and home), and all future attempts to load the app now fail with this error screen. A second, rarer failure mode is an infinite refresh loop. Generally, I expect that if, despite my best efforts, I do a manual refresh (from the Android pull-down sheet) while Expo is secretly working on an automatic refresh, I will hit one of these failure modes. I’ve learned that if nothing seems to be happening on the device, saving my code again is a much safer way to give it a “kick” than using the reload button. Sometimes, it seems like a live reload completes in as little as 5 seconds, but without any visual feedback on the screen, it is hard to tell when the reload started.

Slow download and load times: Android takes many times longer to download the bundle, and to run the bundle. It can take something like up to 10 seconds just to download the bundle, compared to a second or two (or under a second) on iOS. Manual reload and live reload seem to have totally different behavior, here. As described above, live reload shows no feedback about what it’s doing and seems to take anywhere from 5 seconds to forever (I don’t really know the exact range). A manual reload shows download progress, and seems to take around 10 seconds, most of which is spent downloading!

It would be so awesome to have an Android dev experience on par with the iOS experience. I’m puzzled about why Live Reload works the way it does on Android, and why downloading the bundle is so slow.

2 Likes
#2

Hey @dgreensp - thanks for the feedback and for bringing this to our attention. We’re aware that the load experience on Android is not on par with iOS, and not where we’d like it to be in general. The best immediate fix I can suggest is to try serving your project via localhost or LAN (exp r --localhost / exp r --lan / choose the corresponding option under Host in XDE) if possible, as the tunnel tends to slow down all client-server communication considerably. I’ve found that live reload tends to work more reliably when I’m serving my project via localhost.

We’re hoping to be able to address a lot of your feedback in the next few SDK cycles after 27, but I don’t have much else to suggest right now. Sorry this has been so frustrating, and thanks again for the post – we really hope we can improve your experience soon!!

#3

Thanks for the reply, Eric.

I can’t use localhost with an external device, right? Only a simulator?

I use --lan at home, but I’ve found the tunnel to be pretty snappy, and a life-saver when on a public wifi network where the LAN setting doesn’t work, presumably because the port/connection is blocked by the access point. :slight_smile: Something must be limiting the download speed of the bundle in LAN mode besides the speed of the network.

#4

I also face the same issues as @dgreensp, most of the times, I have to close the expo app on my Android device and relaunch it to update my app.

closed #5

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.