I had some really strong ideas and wrote them down in a blog post and it went really well.
-no one, ever.
So, I’ve had some feedback on my last post, and there are some other ideas and arguments that I want to explore/validate:
- CSS was shortchanged by design from the start. It might have been. I want to get my facts straight about this first, though.
- My feelings about CSS-in-JS are the same type of feelings other people had about SASS. I don’t think this one is accurate, because SASS keeps separation of concerns while making CSS more useful. I think it maybe isn’t the greatest for maintainability on large teams because of the cognitive overhead of tracking down mixins, etc. However, this particular comes from my personal experience with dev teams that were trying to be too damn clever for their own good. In general, I use .scss for most of what I do.
- I *do* typically think that it’s important to examine all ideas for validity. I also believe I have evaluated CSS-in-JS and have rejected it soundly, and for specific reasons. I recognize that some developers see it as a solution that helps them ship their work- and while that may be accurate, I still strongly object to it being included in discussions about long-term solutions.
- It’s possible to write the CSS for components with out a ton of JS nonsense. I know this because I have done it.
- I don’t think I object to single-file components. I think it is distinctly the separation of concerns that is so worrisome to me. Additionally, I recognize that some folks might see this as “okay, it is separation of concerns, we just separated the concerns differently.” Perhaps we can agree to disagree.
Web development is changing. There is a great deal of uncertainty that we must consistently be okay with. I even gave a talk about this and still strongly believe it.
It’s also okay to soundly reject bad ideas because of the way they have ignored fundamentals, while still working toward the right ones. The cost of some ideas is just too high and we cannot willfully ignore that.
In the meantime, how about we do better at accessibility and focus on that instead? I can’t help but wonder if our energy would be better spent on solving problems we genuinely have instead of reinventing the wheel on a time-tested solution that already exists (and excluding a whole lotta devs as a result).
More thinking to do about things, to be sure. I’m very grateful that I have people in my life who can thoughtfully give me feedback that helps me think more deeply and grow as a person.