I hereby decree

by David LeMieux

 

CSS is a powerful language used to describe how a webpage should look. It has come a long way over the years and can be used to create seemingly limitless design. Except for when it can't.

I am not great at coding with CSS. I will admit right here that while I have an understanding of the language and the way it should work, I couldn't get by without having to look up every property on the web. I feel like I must not be approaching web design in the right way because I look at all the wonderfully designed websites in the world and it becomes apparent to me that CSS can do a lot and is used to great effect. Whenever I try to use it I bumble around and ultimately end up in a situation where nothing seems to work.

For example: vertical centering. I know there are ways to accomplish it but it always seems like I am implementing a work around and not letting the language do its thing. Why can't

vertical-align: middle
just work?

Another thing I find myself wanting is a way to do math in the CSS. I know with things like SASS some expressions are available, and I know, as with vertical centering, there are ways to get this done, but doing something like having one box be 100% width of its container minus 10px would be more awesome if I could just write 100% - 10px. I understand there is support on the way yet I remain confused why we don't have it already.

Really this is the rant of an ignorant developer saying something is 'too hard'. I can certainly try harder and try to learn and apply the styles as needed to achieve my desired output, but so many times I find myself trying and then just revert to JavaScript because it seems to be that much easier.

Each new design project I get I try to use CSS as much as possible. Last year's family card was just such an exercise. I also want to be clear that I like to design and lay things out. I am not just a coder why has to do a GUI from time to time. That said, CSS seems to provision and provide for great depth in design and layout, yet the simple, obvious answers never are.

I will continue to learn and try and grow, but I also have CSS will do the same. We can grow together. Hopefully in another year you'll hear me singing the praise of CSS and looking back at this post with some embarrassment.

 

blog comments powered by Disqus