HackedThe optional chaining operator, “modern” browsers, and my mom

The optional chaining operator, “modern” browsers, and my mom


- Advertisment -

Eric Bailey recently wrote on CSS-Tricks about testing your website on a crappy laptop and it reminded me of this anecdote from my own life.

About a month ago, I was talking to my Mom on the phone. At the end of the call, she asked if I could help her with a computer problem on my next visit. “Of course,” I replied. Most of my parents computer issues are easy fixes: ensure all the cables are plugged in, restart the computer, you know the drill.

When I arrived at my parents’ house, I asked my Mom what was wrong.

“I can’t open this website I always use to make a reservation to volunteer. It doesn’t work on our computer and it doesn’t work on my iPad. But it does work on Mike’s (my brother) laptop, so I’ve just been using his. Can you fix it?”

Hmm. Something that works on one computer, but not on two others. That doesn’t sound like an unplugged cable. What could it be?

- Advertisement -

First I looked to confirm the problem. I pulled up the website on my parents’ computer as well as my Mom’s iPad and sure enough, the website didn’t load. Then I opened it on my brother’s laptop, and it did load. My Mom’s verbal JIRA ticket was right.

This problem started to sound all too familiar: a website that doesn’t work across multiple devices.

My first thought was, “well it can’t be a browser issue. It’s not like my Mom is using Internet Explorer! She has relatively modern tech: an iPad (Safari) and a Chromebox (Google Chrome).”

But the more I thought about it—a website that works on some devices but not on others—the more I realized this had to be a browser issue.

So I looked at the version of Chrome on my parent’s computer. Version 76! I knew we were at ninety-something in 2022, so I figured that was the culprit. “I’ll just update Chrome,” I thought.

- Advertisement -

Turns out, you can’t. From what I could gather, the version of Chrome was tied to ChromeOS which couldn’t be updated because of the hardware. No new ChromeOS meant no new Chrome which meant stuck at version 76.

But what about the iPad? I discovered that my Mom’s iPad was a 1st generation iPad Air. Apple stopped supporting that device in iOS 12, which means it was stuck with whatever version of Safari last shipped with iOS 12.

So I had two older browsers that couldn’t be updated. It was device obsolescence because you couldn’t install the latest browser.

“But what was the culprit in the website,” you ask? After opening the developer tools in Chrome and looking at the console, I discovered the website authors were shipping JavaScript that used the optional chaining operator (?.), an unsupported syntax in older browsers that caused the entire website to fail.

Photo of the Chrome developer tools showing JavaScript code using the optional chaining operator.

- Advertisement -

In my brain, I always thought of Safari and Chrome as “modern” browsers. But even Chrome, an “evergreen” browser, failed because it wasn‘t on an “evergreen” operating system (or hardware).

I went back to my Mom and told her I’d found the issue. In essence, “your computer is too old and I can’t update it.” This only reconfirmed my parents’ belief that device makers deliberately make things go out of date so that you have to go buy new hardware every couple of years.

I wanted to try and explain to my Mom that, while true for many native applications, browsers shouldn’t go out of date so easily because of hardware. “This isn’t your problem Mom. You should’t have to go buy new hardware. This is a fixable problem by the people who make that website. They should be making their website’s code more accessible to legacy devices. Just because you don’t have a browser that can run ECMAScript 2020, you should still be able to access and use this website.” But I didn’t feel like explaining the idea of progressive enhancement to my Mom—or even what a compiler like Babel is useful for.

The real-life impact of our technical decisions really hit home to me once again: my Mom had trouble volunteering and participating in her local community because somebody shipped the optional chaining operator in their production JavaScript.

Reminds me of this line, which I love, from the W3C’s design principles:

The internet is for end users: any change made to the web platform has the potential to affect vast numbers of people, and may have a profound impact on any person’s life.

NOW WITH OVER +8500 USERS. people can Join Knowasiak for free. Sign up on Knowasiak.com
Read More

- Advertisement -

1 Comment

  1. > Turns out, you can’t. From what I could gather, the version of Chrome was tied to ChromeOS which couldn’t be updated because of the hardware. No new ChromeOS meant no new Chrome which meant stuck at version 76.

    This is the most surprising part of the article. If ChromeOS does not allow the browser to be updated after the hardware has reached end-of-support, I would recommend it to nobody, ever.

You might also likeRELATED
Recommended to you

Show HN: Racompass 1.1.x – An Advanced GUI for Redis and Redis Modules

Modern. Efficient. Fast. A faster and robust Redis management tool. For developers that need to manage data with confidence. Requires OS X 10.11+, macOS 10.15 recommended A tool for Redis. Interact with your data with functionality. Racompass empowers you to make smarter decisions about developing and more. What's New in Racompass 1.1 Racompass 1.1 supports…

A few things I’ve learned about livestreaming

“Thanks” to the pandemic, I’ve spent much more time figuring out how to deal with video and live streaming...

Pixel steer clear off me from calling emergency products and companies – three years ago

Three years ago, I got hit by a motorcycle and tried to call emergency services on my Pixel. My Pixel tried to send my location to emergency services, failed, and froze entirely. When I rebooted and tried again, the exact same thing happened. I couldn't call for an ambulance on my Pixel. After I reported…

Code Emails like you code websites

Something went wrong, but don’t fret — let’s give it another shot.
- Advertisement -

Must read

Microsoft to Acquire Activision Blizzard

Legendary games, immersive interactive entertainment and publishing expertise accelerate growth in Microsoft’s Gaming business across mobile, PC, console and cloud. Microsoft announced plans to acquire Activision Blizzard, a leader in game development and an interactive entertainment content publisher. The planned acquisition includes iconic franchises from the Activision, Blizzard and King studios like “Warcraft,” “Diablo,” “Overwatch,”…

VR, VFIO and how latency ruined everything

I’ve been running my all-in-one PC for a while now. It was my desktop, my NAS and my gaming PC. However, during the next couple of months I kept hitting small bumps along the road. Most of these were quite straightforward to fix, but there is one that finally convinced me to go back to…
- Advertisement -