DEV Community


Discussion on: Rapid Prototyping with Utility-First CSS

xyn profile image
Mydrax • Edited

I kinda disagree with the "inline styles are taboo" statement. Inline styles can be useful for situations where you just want to change a couple style properties. If you are already using Tailwind it makes sense to call it taboo, because there's probably a class that does that already.

PS: You could use codeblocks for when you write code. Just gotta cover the code in three backticks.

hrishikesh1990 profile image
hrishikesh1990 Author • Edited

I use inline styles quite often too and you're right, they are handy when you want to have something changed super quick. But they pose a big challenge when I come back months later & want to re-style the element(s).

I actually can't think of any +ve for inline styles except that they are hacks you put in when there's extreme time crunch.

Thanks for the tip - just changed it to code blocks :)