Yesterday, I wrote about the web development community seems stuck in a never-ending Ground Hog Day of reinventing the wheel.
So what’s the alternative? Working with the grain of the web rather than against it.
Taoism is a philosophy and religion focused on acknowledging the nature of things and working with that nature instead of against it. Water flows around rocks, and in doing so, both gets where it wants to go and erodes away the rock over time, making its path shorter and easier.
Web development can work the same way!
Rather than fighting the nature of how the platform works, we can lean into each part of the stacks strengths.
Many CSS libraries view the cascade (literally the first C in CSS) as a bug, and work hard to fight against it. It’s how we end up with comically unmaintainable CSS in our HTML.
The cascade let’s me keep my stylesheets small, lean, and performant. It means I don’t have to redeclare styles for the same element over and over again for each component I include it in.
Imagine having to rewrite the same styles for buttons used to submit your contact form, buttons used to sign up for your newsletter, and buttons for a call-to-action box.
I’m pragmatic enough to recognize that there are times where the platform simply doesn’t offer what you need out-of-the-box. And sometimes that means reaching for tools to make doing that thing easier.
When I choose tools, when I evaluate them, one of the biggest questions I ask myself is: “Does this work with the grain of the web, or against it?”