| I completely disagree. To fix the css + jsx in one file, just write your styled components at the bottom of your component. If you ever seen a react component completely riddled with Tailwind, you'll realize how messy and uncoordinated it looks. Even I would consider switching between two files just to avoid that style of css. Furthermore the necessity to utilize horizontal scroll because adding 10+ more rules will inevitably break your prettier printWidth rule is, by far, the most annoying aspect of Tailwind. absolute inset-0 bg-gradient-to-r from-cyan-400 to-sky-500 shadow-lg transform -skew-y-6 sm:skew-y-0 sm:-rotate-6 sm:rounded-3xl
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
linear-gradient(45deg, #fff, #000);
box-shadow: 1px 1px 1px 0 rgb(0 0 0 / 0.05);
transform: skewY(60deg);
border-radius: 4px;
transform: rotate(60deg);
Consider these two snippets, after time of not looking at your css code, do you think 10+ rules on one line is maintainable?Not even close, ask yourself to change a css property - you would have to iteratively go from left to right until you find it, whereas looking from top down you can immediately catch the css rule you want to find. Succinct doesn't mean maintainable, and sometimes verbosity does. Tailwindcss isn't even close to being the future. |
And you can split, and sort classes with editor plugins which makes it almost equally good as your example.