The Simplest Darkmode

This Friday the 13th, let's get dark. In this article (opens new window), there's a really simple definition of dark mode that I want to try.

The filter (opens new window) CSS property is new to me, so I'll certainly use it more in the future. But what I did for this implementation was perhaps the most un-react, un-gatsby thing ever: I created the dark class but changed it in the default javascript way, which meant getting the class name that was generated.

I'm sure there's a less hacky and awful way to do this, but let's say it adds to today's horror theme 😃.