8 TailwindCSS Classes I Wish I Found Earlier

Поделиться
HTML-код
  • Опубликовано: 1 дек 2024

Комментарии • 94

  • @tomisloading
    @tomisloading  9 месяцев назад +14

    Are a couple of these kinda just basic CSS? Yes.
    Did I somehow never know about them until accidentally finding them with TW intellisense? Also yes.
    Show me a man who say’s he knew you could style input cursors and I’ll show you a liar 👨

    • @aguywithoutaname
      @aguywithoutaname 8 месяцев назад

      This is one of those videos that I don't think I need until I start watching and then I can't close it. No amount of docs reading would give me this information. You did well man !

  • @0xAndy
    @0xAndy 9 месяцев назад +70

    1:31 Instead of sr-only for the buttons, you could add aria-label="the text" which would accomplish the same thing without inserting more nodes into the DOM.

    • @tomisloading
      @tomisloading  9 месяцев назад +10

      Very true! I like sr-only when I want to also show the text at specific break points, essentially as an alternative to display none. Also useful for text that’s ACTUALLY only for screen readers, or things like custom toggles/switches/checkboxes

    • @8YEight
      @8YEight 9 месяцев назад +2

      A sr-only text should be preferred over an aria-label whenever possible. Screen reader software is not required to support the ARIA standard so there’s an always a risk that these attributes are not supported.

  • @Ony3dika
    @Ony3dika 9 месяцев назад +9

    Absolutely love this video, will mostly likely be using the space between property a lot!

    • @tomisloading
      @tomisloading  9 месяцев назад

      It's SO useful :)

    • @gadoosher
      @gadoosher 9 месяцев назад +1

      Hey@@tomisloading ! This was a killer video, will definitely be checking out more of your stuff. What's the benefit of space between as opposed to using gap? Cheers!

    • @tomisloading
      @tomisloading  9 месяцев назад

      @@gadoosher Just that you don't have to add flex or grid! Generally advised to use gap for complex use cases though. Space between essentially just adds margin to all but the first element in the group. Wrapping elements and grid won't play well with space

    • @gadoosher
      @gadoosher 9 месяцев назад

      oh doi lmao. Good call 😅@@tomisloading

    • @Omar_Al_Seddik
      @Omar_Al_Seddik 9 месяцев назад

      I honestly don't get the point. Why not just use gap?

  • @re.liable
    @re.liable 2 месяца назад +1

    I also just recently discovered "divide width" and "space between". Unfortunately they conflict with my preference of elements managing their own borders and margins (and paddings) so I haven't been able to use them as much. Definitely handy with elements I do not "own" though (e.g. injected)

  • @CodeWithBehram7497
    @CodeWithBehram7497 3 месяца назад +1

    learned alot pf new features today thank bro and more power to u❤

  • @loground
    @loground 9 месяцев назад +1

    legend, love your videos

  • @Deus-lo-Vuilt
    @Deus-lo-Vuilt 8 месяцев назад +1

    Thanks , I love Tailwind ❤

  • @rahulxcr
    @rahulxcr 9 месяцев назад +2

    Loved the video. Very helpful classes.

  • @ppcalpha1042
    @ppcalpha1042 9 месяцев назад +1

    you have the best videos dude!!!

  • @Harmxn
    @Harmxn 9 месяцев назад +1

    space is a big one. I was always making Flex boxes and adding a Gap.

  • @farizsofyan
    @farizsofyan 9 месяцев назад

    I just discovered gradient last month and i got mindblowing, how cool implementation is it 🤯
    The other thing i discovered was custom class to assign new css variable

  • @madukomablessed4712
    @madukomablessed4712 9 месяцев назад +1

    Didn’t know about divide and scroll snap, nice one

  • @deatho0ne587
    @deatho0ne587 9 месяцев назад +2

    Tailwind is CSS in the DOM, just like inline styles. Issue I see is the graident you have at 3:34 most likely would be in more than one place in your project, so just make a CSS class for it.

    • @ChristoferGBG
      @ChristoferGBG 9 месяцев назад +1

      It's beyond insane that anyone with more the six months experience of frontend would even consider tailwind. As you say, inline styling

    • @deatho0ne587
      @deatho0ne587 9 месяцев назад

      There are reasons for it, just like there are reasons for Bootstrap.
      I personally like most projects to have their own CSS that is a cross of Bootstrap, Tailwind and others. Most of time it is compent level (bootstrap) but when you need a slight variantion (tailwind) there should be a few in the repo that everyone can use.

    • @unknownguywholovespizza
      @unknownguywholovespizza 7 месяцев назад

      ​@@ChristoferGBGnah it eases development and have many pre made classes

  • @ronitgurjar5747
    @ronitgurjar5747 9 месяцев назад +1

    Oh 🔥🔥🔥hey Tom, i see the loading family has grown quite big🔥🔥🔥 congrats man🗿🍷

    • @tomisloading
      @tomisloading  9 месяцев назад +1

      Thank you!!! A bit more every day 😁

  • @wyndmill
    @wyndmill 9 месяцев назад +1

    this is a great video your pacing is perfect

    • @tomisloading
      @tomisloading  9 месяцев назад

      THANK YOU! Feel like I finally found the right balance of not completely blabbering and actually explaining what I'm doing 😂

    • @chiroyce
      @chiroyce 9 месяцев назад

      Small world we live in!

  • @mdm9b
    @mdm9b 9 месяцев назад +2

    Ur good at explaining, will watch the video later
    thanks

  • @fmgthoryt8859
    @fmgthoryt8859 8 месяцев назад +1

    2:23 instead of w-8 h-8 use size-8.

  • @352Pking
    @352Pking 9 месяцев назад +2

    Violet600:wave: buying purple partyhat

  • @mdm9b
    @mdm9b 9 месяцев назад +1

    gaps classes are so useful 👍

  • @CodeWithSasha
    @CodeWithSasha 9 месяцев назад +1

    Thanks! Great video

  • @hichambronson6533
    @hichambronson6533 9 месяцев назад +4

    Sr-only is too hacky, why add a whole span element and hide it? You can just add an aria-label to those buttons, which is considered best practice.

    • @DarlantenCaten
      @DarlantenCaten 8 месяцев назад

      Its just an example. There are many valid cases where an element is useful only for screen reader users.

  • @AzirChai
    @AzirChai 9 месяцев назад +2

    Hey! Nice video! Learned alot, also for the example with the accent color box thing, you used "h-8 w-8" thats totally fine, but you can use "size-8" its the same but both in 1, its handy for boxes / squares / circles, just wanted to mention it! Nice video again!

    • @tomisloading
      @tomisloading  9 месяцев назад +1

      WOAH I did not know that!!! If ever make a follow up to this video, I’ll be adding this 😂

  • @Deus-lo-Vuilt
    @Deus-lo-Vuilt 9 месяцев назад +1

    Thanks , Tailwind ❤

  • @DMZT_dhruv
    @DMZT_dhruv 9 месяцев назад +1

    absolutely time saving and informative

  • @lollery3253
    @lollery3253 9 месяцев назад +1

    what font are you using? looks good!

  • @prateek5668
    @prateek5668 9 месяцев назад +1

    Very Helpful!!!

  • @joshua_226
    @joshua_226 9 месяцев назад +1

    Shiiiee this is f-ing cool

  • @bhavishs5830
    @bhavishs5830 9 месяцев назад +1

    This is awesome

  • @godofwar8262
    @godofwar8262 9 месяцев назад +3

    I am also a noob who doesn't know these features 😂 and also please make a video on best practices of tailwind css in code means a beginner level to pro level real example

    • @tomisloading
      @tomisloading  9 месяцев назад +1

      I've been coding for ~6 years and somehow JUST FOUND OUY CAN STYLE THE CARET OF AN INPUT?!?!? Amazing 😂

    • @jkibble98
      @jkibble98 9 месяцев назад +1

      @@tomisloading to be fair it's still relatively new. There are tons of newish well supported CSS features which most people don't know. The discoverability of these is a huge reason people love Tailwind

  • @itzzRaghav
    @itzzRaghav 9 месяцев назад +1

    Great video

  • @zerosandones7547
    @zerosandones7547 9 месяцев назад

    what. does divide (in 0:45), work with table rows as well?

  • @Patrick-pu5di
    @Patrick-pu5di 9 месяцев назад

    as someone who doesnt use tailwind everything about this looks fucking insane like....WHATT!!

    • @unknownguywholovespizza
      @unknownguywholovespizza 7 месяцев назад

      I was also like this but once you get used to it, you'll become addicted

  • @Munch_92
    @Munch_92 9 месяцев назад +2

    Webdevsimplified quite simply robbed your video champ.

    • @tomisloading
      @tomisloading  9 месяцев назад +3

      Hahaha he seems like a good dude, I’m sure he didn’t take it 🙂 And we’re all just trying to share knowledge out here anyways, he’s got 150x the audience I do, if he can help 150X the people that’s fine with me!

    • @SilverPaladin
      @SilverPaladin 2 месяца назад

      @@tomisloading I like the cut of your jib! Humans should share by default, to make the collective better! Selfishness is cancer to society.

  • @a7mdbest15
    @a7mdbest15 9 месяцев назад +1

    ok, i only know the space between, every thing else is just new to me

  • @joshuadeguzman2911
    @joshuadeguzman2911 7 месяцев назад

    What about the peer?

  • @fatmaabdelmageed2926
    @fatmaabdelmageed2926 3 месяца назад

    how to convert prime view templete frome prime flix in tailwiand

  • @bozzhik
    @bozzhik 9 месяцев назад +1

    yo very good video

  • @bipinthomas6695
    @bipinthomas6695 9 месяцев назад

    please make the playlist

  • @HamadAbdulla_7
    @HamadAbdulla_7 9 месяцев назад +1

    Thank you

  • @nathnaelgetachew7379
    @nathnaelgetachew7379 9 месяцев назад +1

    What i want to know is how to order my classes😢

    • @tomisloading
      @tomisloading  9 месяцев назад +2

      Prettier plug-in for tailwind does it automatically :)

  • @itsdrvgo
    @itsdrvgo 9 месяцев назад +1

    I only knew about space-x/y... XD

  • @moneyfr
    @moneyfr 9 месяцев назад

    i made a tailwind killer with unocss can i send to you ?

  • @RikasMohomed
    @RikasMohomed 9 месяцев назад +1

    Thanks

  • @doren_dev
    @doren_dev 9 месяцев назад +1

    Cool

  • @guuhuu1337
    @guuhuu1337 9 месяцев назад +118

    "I Wish I Found Earlier" - just open the docs

    • @temitopedavid9508
      @temitopedavid9508 9 месяцев назад +14

      Ungrateful guy

    • @NotherPleb
      @NotherPleb 9 месяцев назад +5

      Do you check every item in amazon when shopping?

    • @lufenmartofilia5804
      @lufenmartofilia5804 9 месяцев назад

      ​@@aiyazmostofa1501to be honest the docs of tailwind is small and easy to navigate

    • @invinciblemode
      @invinciblemode 9 месяцев назад

      @@aiyazmostofa1501yes I do

    • @GustvandeWal
      @GustvandeWal 9 месяцев назад +3

      This is a RUclips video, dude 🙄

  • @MarkSnape
    @MarkSnape 9 месяцев назад

    Sorry, can't get past having to read "className"

  • @Hadi-gd7ul
    @Hadi-gd7ul 9 месяцев назад +2

    Remember kids, stay away from margin, always use padding or gap

    • @troublesum
      @troublesum 9 месяцев назад

      why?

    • @Hadi-gd7ul
      @Hadi-gd7ul 9 месяцев назад

      @@troublesum just don't, you're welcome

    • @paragateoslo
      @paragateoslo 9 месяцев назад +4

      Depends. If you want even spacing use gap, if you need different use margin.

    • @hoorahforsnakes
      @hoorahforsnakes 9 месяцев назад

      What terrible advice.
      Gap only applies to flexible element layouts, and also has some drawbacks in niche scenarios that i won't get into the specifics of.
      And padding applies the spacing in the inside of an element instead of the outside, which will cause issues if your elements have backgrounds or borders

    • @Hadi-gd7ul
      @Hadi-gd7ul 9 месяцев назад

      Also remember kids, always use flex@@hoorahforsnakes

  • @thatanimeweirdo
    @thatanimeweirdo 9 месяцев назад +1

    Good video, but by god do I hate tailwind

    • @tomisloading
      @tomisloading  9 месяцев назад +2

      Hahaha, I know it’s tough to look at at first, but it’s amazing once you get over your first reaction to it imo!

    • @thatanimeweirdo
      @thatanimeweirdo 9 месяцев назад +1

      @@tomisloading I've used it for about a year in an existing project, it's just something where the cons outweigh the pros for me, even when understanding all the concepts and knowing all the utility classes. I did however apply tailwind's concept of color variables since then (primary-50 to 950 and so on), so there was a net positive learning it and getting familiar with it in a professional level.

    • @tomisloading
      @tomisloading  9 месяцев назад

      @@thatanimeweirdo haha fair enough! The color system is super nice for sure :)

  • @avwie132
    @avwie132 9 месяцев назад

    Don’t fucking blur them man

  • @darlleybrito4198
    @darlleybrito4198 9 месяцев назад +1

    Group, Peer, Size, *:,