Jake Archibald Profile picture
Developer advocate working on Chrome. Once swam to the end of an infinity pool. No thought goes unpublished. 'IMO' implicit. He/him.
Jan 10, 2022 11 tweets 3 min read
🧵 @rauchg's Wordle clone didn't work on Chrome for Android. It's fixed now, but there's an interesting lesson here: Avoid relying on input device events if at all possible.

… A lot of folks may consider this advice obvious when thinking about mouse events, "not all users may be using a mouse", but the same applies to other devices like the keyboard too.

Nov 26, 2021 8 tweets 2 min read
Ugh, I know I'm jumping on a bandwagon here, but it's really pissed me off. The absolute worst bit is "Don't embrace being a copy-pasta programmer whose chief skill is looking up shit on the internet"



I recently wrote jakearchibald.com/2021/cors/ which folks seemed to enjoy. I think I know this stuff better than most developers… you think I wrote that stuff off the top of my head? No, I "looked it up" in the spec to make sure I was getting it right, I even discovered new details…
Jun 9, 2021 4 tweets 1 min read
So yesterday was a weird day of:

a) Lamenting that web access is dependent on a few central services like Fastly.

b) Celebrating that iOS is going to pipe all web traffic through a VPN controlled by Apple. (the VPN sounds good, and I imagine it could be disabled by the user in some way, but the juxtaposition was weird)
May 4, 2021 4 tweets 2 min read
😬 localStorage is broken in Safari 14.1.

Tabs end up with seperate localStorage for reading, but the same localStorage for writing. This will likely result in data loss for users. (h/t @forresto)

bugs.webkit.org/show_bug.cgi?i… Also, any cross-tab communication that relies on the 'storage' event (such as BroadcastChannel polyfills) simply won't work.

Demo: static-misc-3.glitch.me/localstorage-b…
Dec 10, 2020 8 tweets 2 min read
A few people has trouble getting the new version of squoosh.app. Here's what happened: Part 1: I accidentally changed the URL of the service worker. That was just a dumb mistake developers.google.com/web/fundamenta…

I fixed that, but folks still weren't finding out about the update…
Aug 20, 2020 4 tweets 2 min read
Whenever I need to clamp a number between a `min` and a `max`, it takes me ages to convince myself this implementation is correct.

But yeah, it's easy! I just want the min of the max of the num and the min and the max. num = Math.min(Math.max(num, min), max); The min of the max of the num and the min and the max. A licky boom boom down.
Apr 18, 2020 81 tweets 13 min read
One of our cats is missing and it's basically fucking awful I have a plan
Feb 15, 2020 9 tweets 4 min read
@heydonworks Did I ever tell you about the time someone called the police on me because they found my email in the source of their webmail client? @heydonworks
Jan 3, 2020 13 tweets 4 min read
All code using array.reduce should be rewritten without array.reduce so it's readable by humans *mutes thread* Ok ok, fair enough, there are cases where array.reduce is the best thing to use.

Specifically, cases where you want to look really smart and don't care about readability.
Nov 20, 2019 29 tweets 16 min read
We had a lot of fun between the talks at #ChromeDevSummit. For example:

➡️ I get stuff wrong.
➡️ @DasSurma can't press buttons.
➡️ @aerotwist is a cheat.
➡️ Someone wrote a bot.
➡️ SURJIKO LIVES.

Let's dive in: We started with the classic "we can't hearrrr you" intro. Yeah. I know. Buuuuut, check out the amazing jumpers @kosamari made.

Also, she teaches us about the "pacman circle".