simevidas,
@simevidas@mastodon.social avatar

time.com uses Tailwind for some reason

devolute,
@devolute@mastodon.social avatar

@simevidas is .z-99999 a thing in ?

simevidas,
@simevidas@mastodon.social avatar

@devolute Not by default, but authors can set custom values in brackets, e.g., class="z-[99999]"

lucas,

@simevidas I never understood why people use it. It seems like inline styles with extra steps.

zack,
@zack@toot.cafe avatar

@lucas @simevidas

With inline styles, you have to change every element that uses a particular style to update your design. With utility classes, you update the style for the class (in one location) and every element uses the updated style.

This was always the biggest issue with inline styles and utility classes solve that.

lucas,

@zack @simevidas unless your utility class is called text-bold. I'm pretty sure that's always going to be the one that creates bold text, and I'm not sure it's a good idea to change it to not being bold because one of the places where you used it shouldn't have bold text anymore. Same with colours. And that's how I see tailwind and friends being used in the wild.

zack,
@zack@toot.cafe avatar

@lucas @simevidas sure. Some are pretty static. I still think utility classes are an improvement over inline styles.

As for colors, most systems I've seen use numbers to indicate the scale. So red-100 thru red-800 should always be some shade of red for obvious semantic reasons but you could change the shades of red with proper care.

I'm not arguing for tailwind. I've never used it. But I have used utility classes, though always in combination with normal semantic classes, where appropriate.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • ngwrru68w68
  • DreamBathrooms
  • thenastyranch
  • magazineikmin
  • InstantRegret
  • GTA5RPClips
  • Youngstown
  • everett
  • slotface
  • rosin
  • osvaldo12
  • mdbf
  • kavyap
  • cubers
  • megavids
  • modclub
  • normalnudes
  • tester
  • khanakhh
  • Durango
  • ethstaker
  • tacticalgear
  • Leos
  • provamag3
  • anitta
  • cisconetworking
  • JUstTest
  • lostlight
  • All magazines