News for hackers. Stuff that matters.
Re:Tailwind Is a Leaky Abstraction by toastal on Tuesday November 29, 2022 @09:31AM (#33788029)
But CSS-in-JS was a mistake. Unless you want to start coupling your build tools even harder to get nonces on every compile, your CSP will require `unsafe-inline` which is bad for security. The simpler solution was to do CSS in CSS and keep your tools simple and minimal.
Re:Tailwind Is a Leaky Abstraction by JoeyJoJoJr on Tuesday November 29, 2022 @04:23PM (#33793504)
I had very few issues with just creating one scss file for every component module, ie ProfileCard.tsx and ProfileCard.scss, with sub components like ProfileCardimage being a nested selector in the scss tile. I don’t think you really need complicated design systems or atomic utilities anymore, just a bunch of variables for spacing, fonts, colors, etc. For any given component I knew exactly where to look for its styles, and it is all there. If the scss files becomes unwieldy as requirements change, it’s easy to just re-write it.