You know those kid’s bikes that you can upgrade from a balance bike to a something that will take your child to elementary school? CSS did something like that for me.
I can still remember the days of floating layouts. We used a lot of hacks to get things to behave like we wanted them to, like the Clearfix or browser-detecting media queries. The designs were just starting to move from table-based layouts to the box model, which allows a bit more freedom and flexibility in its implementation, but pixel-perfectness was still the gold standard of layout execution.
I felt clever writing CSS under those limitations. My code was illegible, my hacks were obscure and I got the thing working somehow. CSS just wasn’t as good at getting the job done in a clean and efficient way (which is probably where it picked up its bad reputation that it still has today).
But CSS grew up and so did I.
Webfonts were a huge milestone for me. I could do some typography on the internet without using images, and their sprites respectively. Gradients and rounded corners as well for similar reasons. It felt like taking the training wheels off my code.
I recently explained to a younger developer what image sprites were. He was baffled that we needed something like this and amazed at the ingenuity and jank of it in equal parts. Hey, skeuomorphism can be really hard with just SVGs! Speaking of which, SVGs have only been natively supported in Internet Explorer since version 9.
I don’t need dirty hacks anymore just to code basic layouts. grid
and flex
are powerful tools (Firefox is even pushing for native masonry). Layouts have become more complex, but media queries help to adapt to the user’s needs. Websites aren’t as monolithic anymore. We’re putting them together component by component. I still love BEM and I really like CUBE as methodologies to do so, and I’m very looking forward to introduce and container and style queries to my workflow.
Over time, I added parts that helped me achieve more mature projects fast and efficiently. I replaced the training wheels with a crankset, and shifters, and proper brakes… I learned to use the right tool for the job and CSS kept providing me with them.
Top comments (1)
Great analogies in this article @iamschulz. I feel this way as well since I've been dealing with CSS since the late 90's/early 2000's. I actually haven't heard of Cube so I'll definitely check that out.
I'm certainly grateful for no longer needing polyfills, custom resets (or searching for the most effective ones), and no longer needing to support IE.