My website was no longer rendering correctly on android... I tarcked it down today to a bug in PhotoSwipe 3.0.5 that I've been using on Android since way back when.
This led me here:
But updating seemed like a pain. Lots of new features I didn't need.
So I looked into mobile debugging (again):
I added a way to fake out console.log() on mobile.
Then I added a try around the code that was erroring out and a console.log(error.stack) printout the stack.
That led to a line with this regex:
Which I tested on: https://regex101.com/
With this: Mozilla/5.0 (Linux; Android 10; SM-A205U) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.5359.128 Mobile Safari/537.36
I changed the line to this: /Android (\d+.?\d+)/
It was not matching correctly for version 10, because version 10 has no decimal point in it.
And the bug was fixed.
This led me to creating a page, which reminds me why html sucks...
Maybe I'll use pandoc... yeah..
pandoc photoswipe_bug.md -o photoswipe_bug.html
But that produces busted apostrophe's with euro and TM characters showing...
But that breaks the title... so I added this to the top... hackity, hack, hack!
\<meta charset="utf-8" />
https://poleguy.com works on android again!