|

The Mobile Web App Developer’s Dilemma

I’m currently sitting on an Amtrak train from NY Penn to Exton, PA (the Philly-ish area). The ticket taker was coming by on his nifty device scanning tickets, which would then check a database of purchased tickets to confirm the purchase and the identity of the purchaser. However, when we hit a tunnel (and therefore no data connection), the device stopped working; any scans returned “Ticket not found.” You would think that whoever developed this system for a subway/train company would have considered that at times there might not be a data connection, but that didn’t seem to be the case. This is a bit of a dilemma for anyone developing apps for mobile.

I’ve been thinking about this a lot lately since beginning work on a small pet-project that is based on the mobile web. My friend Dave and I were discussing this same issue: web developers assume an Internet connection because that’s been status-quo for us. People aren’t viewing websites if they aren’t connected.

That is changing though; I assume that a lot of developers like me are seeing the value in mobile. This is a very different medium from a desktop or laptop because you cannot assume there will always be a connection (or at the very least a strong one). If you do, your app or website will not always work and you will have some unhappy users. So what do you do?

A: Use Local Storage

Let’s look back at my ticket-taker friend from Amtrak (which I’m assuming is a native app, not a mobile web app). The solution here should have been a fairly simple one: download the ticket information incase you don’t have a connection. And it doesn’t have to be a download-all-the-data thing either. 2 possible solutions are that the ticket taker chooses the train he’s on and downloads those tickets, or the app does it automatically based on time and geolocation (when he does have a data connection). This does raise its own problems; what about multiple ticket takers or syncing, etc. But this is just a temporary solution for when there is no conenction. Once you get it back, proceed as normal, syncing the offline data and alerting the user of any anomalies.

So what about mobile web developers? Websites have traditionally (and until recently, exclusively) required an Internet connection to be viewed properly. How do we make it work without data? Thankfully the fine folks at W3C have been thinking of this and, starting in HTML5, introduced HTML5 Storage APIs. This allows us to cache pages and store data that we can later sync back to the server, once we have a connection.

As I build out my little project I will be experimenting with this a bit, but assuming an offline state has been at the forefront of my mind from the start as should be the case with anyone developing for mobile. Doing this right will be a big step in the direction of popularizing web apps over native apps on mobile devices.

Similar Posts

  • 3 Things I’m Grateful for (August 13, 2021)

    3 things I’m grateful for, this second week of August, 2021: CleanShot X: This handy little app is a fantastic way to take screenshots, mark them up and then easily share them. But the killer feature for me is the ability to make gifs out of screencasts. It’s $29 (once) OR it comes with Setapp….

  • | |

    Some general stuff.

    Note: This article was published while I was in my early 20s. I was much younger and dumber. Please don’t hold it against me. One of the perils of having a 20+ year old website!First off, today’s Questionable Content so so good, i feel i need to share it with you. Second off [i guess],…

  • |

    Podcasts I Listen to Every Week

    At CoalWork this morning, the guys and I were discussing podcasts that we’ve been listening to and I thought it would make a good blog post to list my favorites here. I’ll also extend the challenge to my friends Colin, Kyle, & Nick Benson. Here are mine:  Stuff You Should Know Stuff You Missed in…

  • On Coming Up with Content Ideas

    One of the worst feelings as a content creator is having no ideas for the day/week/month. Coming up with good content can be hard, stress-inducing, and lead to burn out or anxiety that frankly isn’t worth it! But I have some good news: there are no bad ideas in brainstorming, and coming up with ideas…

  • | |

    The 7 Day Work Week

    Note: This article was published while I was in my early 20s. I was much younger and dumber. Please don’t hold it against me. One of the perils of having a 20+ year old website!It used to be the case that Sunday truly was a day of rest. Shops closed, people went to church, had…

4 Comments

  1. One of the frustrations I have is that apps have different functions which require different tiers of access, but don’t differentiate between those tiers, and when they can’t get data signal, they shut down entirely. For example- why shouldn’t Words With Friends have a dictionary onboard that lets me make my play (the wireless is used to check possible plays against the database) and then upload it when my commute is over. I have the space for a dictionary download. Or my FitBit, which won’t sync (via Bluetooth) unless there is also a data connection. Why do two things in my pocket need access to the satellite in space to talk to each other?

  2. Exactly Jared! Developers rely too much on a data connection to make their apps work, when it should really be a “work all the time, sync when you can” sort of connection. Instagram’s approach (the optimist’s approach) is a good one. Give positive feedback even without a connection and sync when you have it.

  3. I think this is all a temporary issue. The blanket of data coverage isn’t getting smaller it’s only getting bigger. I believe you’ll have more of an issue trying to lose your data connection than find one in the near future.

  4. Perhaps- at least until then though, we shouldn’t assume the user will always have a connection.

Comments are closed.