Poor formatting aside, this feels like a blogspam tutorial. Feels like a weird article to be this high on HN. I don't see what's notable here in the vanilla JS features that the author is pointing out.
"blogspam tutorial": What a brilliant phrase. My teammate and I were recently joking about the same for Python blogs. If you Google any "simple" Python programming question, the results are overloaded with "blogspam tutorials". I cannot wait until ChatGPT will replace all of that crap.
I remember learning Python for my first time, and being constantly inundated with this junk. That or absolutely decade outdated W3Schools. My fear with ChatGPT is that someone's going to set up a no-effort spam generation machine that will make it harder for beginners.
I was unaware of this `getModifierState` feature. I learned something that may help me in the future.
If you google 'detect caps js' you will find hundreds of articles on this very topic, and bard will provide a correct solution in the top of the window. No need for this to be here.