Hi HN folks,
I am confident writing code in almost all layers of a modern web application now. Node.js/JavaScript, SQL, Angular etc., all took me some time to grasp but now are a breeze to write.
My pain point is currently CSS. I have a good understanding of advanced selectors and properties, but my final CSS code always end up being a mess. I am constantly overwriting styles, writing classes that can't be reused or composed in more than one element and using way more !important rules than I probably should.
Where do I start on the path to write clean, reusable and maintainable CSS?
To me, the key is to think of everything in your app as a component. You should be able to drop the component into more or less any context and it should 'just work'. Following the ideas in the videos will help you accomplish that on the CSS side.
CSS is a Mess - Jonathan Snooks (ex-Lead Frontend Developer Shopify) https://www.youtube.com/watch?v=fAcW-wOFYjw
CSS for Engineers - Keith J Grant (NYSE Engineer, author of CSS in Depth) https://www.youtube.com/watch?v=J-9Tn6AetYA