The Magic of CSS Grid AUTO-FIT vs AUTO-FILL

Sdílet
Vložit
  • čas přidán 26. 02. 2020
  • Visit linode.com/designcourse for a $20 credit on your new linode account.
    designcourse.com - Learn UI/UX from Scratch with my new service (coming soon)
    -- Today, I'm going to show you the junior developer way of handling a common layout pattern, and then the level 1000 xp master full stack developer way of handling the same pattern, using auto fit, auto-fill (and their differences), along with the CSS grid, repeat, minmax and more!
    Codepen demo for this tutorial:
    codepen.io/designcourse/pen/p...
    Let's get started!
    - - - - - - - - - - - - - - - - - - - - - -
    Subscribe for NEW VIDEOS!
    My site: designcourse.com
    My personal FB account: logodesigner
    Coursetro FB: coursetro
    Coursetro's Twitter: / designcoursecom
    Join my Discord! / discord
    ^-Chat with me and others
    - - - - - - - - - - - - - - - - - - - - - -
    Who is Gary Simon? Well, I'm a full stack developer with 2+ decades experience and I teach people how to design and code. I've created around 100+ courses for big brands like LinkedIn, Lynda.com, Pluralsight and Envato Network.
    Now, I focus all of my time and energy on this channel and my website Coursetro.com.
    Come to my discord server or add me on social media and say Hi!
  • Jak na to + styl

Komentáře • 203

  • @DesignCourse
    @DesignCourse  Před 4 lety +89

    Maybe you should auto-fit this youtube channel into your subscriptions list? :|

    • @flavourshub
      @flavourshub Před 4 lety +1

      Already subscribed! 😃 Your videos are my favourite learning resource for coding, your tips are brilliant and very easy to understand. I am building my website from scratch with zero programming knowledge, and your videos helped me tremendously, while making me enjoying the process of learning. Thank you! 🙂

    • @yt-sh
      @yt-sh Před 4 lety +2

      make more on grid please...

    • @MrAndi1281
      @MrAndi1281 Před 4 lety

      Hi Gary, could you please tell in the next CSS Grid Video, if you see a need for grid fallbacks for older browsers?

    • @LabhamJain
      @LabhamJain Před 4 lety

      Actually, @ 3:02 you wrote grid-gap I but use gap bcoz my VSCode Says grid-gap is deprecated What Do You Think Reply With Tagging Me....

    • @poenubstv7229
      @poenubstv7229 Před 4 lety

      Just checked, this is now accepted in most browsers.
      Btw, bit off Topic, If I may ask. Is there CSS Preprocessor that is now accepted in browsers, as in raw like using SASS on the spot?

  • @dizzyrocket2000
    @dizzyrocket2000 Před 4 lety +8

    For those wondering, the "grid-column" CSS property is shorthand for "grid-column-start" and "grid-column-end". He uses the keyword "auto" for "grid-column-start" meaning it doesn't contribute anything to the grid item's placement, indicating auto-placement and a default span of 1.

  • @darbyburbidge8976
    @darbyburbidge8976 Před 2 lety +3

    Late to the party but this video has helped me realize the power of Grid, and that it may actually be flexible enough to be better than flex for what I'm currently working on. Thank you!

  • @code_craft_0
    @code_craft_0 Před 2 lety

    I spent my whole night to solve the problem of auto-fit and you solved it in 1 minute. Changing auto-fit to auto-fill solved my problem.
    A lot of thanks to you. You can imagine how i fill tired when you spent whole to solve a problem but you can't solve it till the morning. 🙏🏻🙏🏻♥️

  • @doomer3729
    @doomer3729 Před 4 lety +49

    funny, this is exactly what i need in my project right now, thank you so much.

    • @dalemoayokunle7330
      @dalemoayokunle7330 Před 3 lety +1

      Same here. I needed just this for my project to run perfectly well and after hours of tackling it decided to check youtube and Gary is the first solution I saw

    • @starbrothersbaskar1758
      @starbrothersbaskar1758 Před 2 lety +1

      @@dalemoayokunle7330 are you his friend?

  • @MrSendlex
    @MrSendlex Před 4 lety

    My thanks to you sir, you always come with a right video at the right time, when I’m in need. Very cool, thx.

  • @Christian-ob9cf
    @Christian-ob9cf Před 4 lety +5

    I usually only do backend at work but trying to become better at the front-end part. I’ve been struggling with these kind of things, thank you for this.

  • @visamalog
    @visamalog Před 4 lety +3

    wow thanks for the vid, I didn't know about such css properties. That's very cool

  • @mirvids5036
    @mirvids5036 Před 3 lety

    I love css grid. Your video appeared so I watched, enjoyed, learnt !
    Liked and subbed.

  • @Alex-xe6bl
    @Alex-xe6bl Před rokem +1

    This 2 year old video really helped me out. My flex ass is struggling on last row because of justify-content: space-between. this video is the solution if you want the last row to be justified left as well.

  • @bohdanartemenko
    @bohdanartemenko Před 4 lety +12

    Thanks, today I'll try to rewrite my small project to use the grid system, seems sweet

  • @miguelbm1989
    @miguelbm1989 Před 2 lety

    I applied everything you said on the video today at my job and it solved everything that would have been so much more complicated hahaha THANK YOU SO MUCH!!!!!!I

  • @stevensavoie856
    @stevensavoie856 Před 4 lety +1

    Thanks for showing me these properties. Now I can change my resume to full-stack developer.

  • @FerencMudrijan
    @FerencMudrijan Před 4 lety

    This is gold Gary! Thanks for teaching.

  • @mdibrahimkhalil2847
    @mdibrahimkhalil2847 Před rokem

    I highly appreciate your tutorial

  • @ItsJustFil
    @ItsJustFil Před 4 lety

    This was awesome! Definitely gonna use it in a future project

  • @anonymouscitizen4235
    @anonymouscitizen4235 Před 3 měsíci

    All I can say is simply brilliant

  • @aspected
    @aspected Před 4 lety +5

    The more I learn about CSS Grid, the more I realise this is what I've needed since day 1. This is awesome.

  • @StudyRumble
    @StudyRumble Před rokem

    I’ve watched hours of videos and tNice tutorials one is the first that explains it in a way a complete beginner could understand! Great video

  • @nicolesantos3864
    @nicolesantos3864 Před rokem

    Your voice made this video informative and entertaining at the same time.

  • @michaeltse4711
    @michaeltse4711 Před 2 lety

    Thanks man, this really helpful!!

  • @forza4674
    @forza4674 Před 4 lety

    Man, you make great videos, thanks a lot!

  • @mdibrahimkhalil2847
    @mdibrahimkhalil2847 Před rokem

    Absolutely Awesome tutorial

  • @robertstimmel1100
    @robertstimmel1100 Před 3 lety

    as always, great video! This was very helpful!

  • @thiagobechelane
    @thiagobechelane Před 3 lety

    That's exactly what I was looking for. Jackpot!

  • @ndyaarthurmartha8748
    @ndyaarthurmartha8748 Před 2 měsíci

    OH MY GOD OH MY GOD! You're a rockstar, SUBSCRIBED Thumbs up times a million

  • @AkbaraliQ
    @AkbaraliQ Před 3 lety

    Fabulous Dude, Thanks for sharing this awesome concept, very helpful.

  • @ErChrys_
    @ErChrys_ Před rokem

    Thank you so much dude, it worked flawlessly!

  • @omeralsoma_
    @omeralsoma_ Před 4 lety

    thank you it hard to me to work without your CZcams channel

  • @rps13br
    @rps13br Před 4 lety

    Man you're nothing but brilliant, absolutely brilliant!

  • @poyakiani7883
    @poyakiani7883 Před 4 lety +2

    Holy Moly :O MAAAAAAN, where have you been all this time??

  • @GammaWraith
    @GammaWraith Před 4 lety

    Killed it Gary, Thanks these tips helped.

  • @pk-19
    @pk-19 Před rokem

    Wow great stuff man

  • @juraev0056
    @juraev0056 Před 4 lety

    Please do more UI/UX stuff. CZcams is lacking those types of videos

  • @roydiga2669
    @roydiga2669 Před 3 lety

    The best dude, I understand How grid works :)

  • @jacquesduplessis6175
    @jacquesduplessis6175 Před 4 lety +4

    Thanks man, you just saved me hours of typing media queries :D
    I'd give you two likes if it were possible!

  • @y3sno4
    @y3sno4 Před 2 lety

    valuable information and top explanation thank you very much!!!!!

  • @kmovies586
    @kmovies586 Před rokem

    Thanks i have been very tried to fix my rows but no ia fix it by tour magic so thankssssss😍

  • @Glow0110
    @Glow0110 Před 4 lety

    Found this very useful, thanks!

  • @IceQub3
    @IceQub3 Před 4 lety

    This video is gold. Thanks

  • @Ahmed_96275
    @Ahmed_96275 Před 4 lety

    Great content man !

  • @arthurgomberg164
    @arthurgomberg164 Před 4 lety

    Great video! Very helpful.Thanks a lot!!!

  • @abdidesign3255
    @abdidesign3255 Před 3 lety

    I have never seen a video simplifies CSS Grid this good

  • @Raghudesign
    @Raghudesign Před 3 lety

    Love this Gary ❤️
    Thanks for sharing 😊

  • @nested9301
    @nested9301 Před rokem

    best explanation thank you!

  • @kamal-ahmed
    @kamal-ahmed Před 4 lety

    Very useful and easy to understand explanation 👍❤

  • @benzinow
    @benzinow Před 2 lety

    Thank you so much, this helped me understand!

  • @luiscolome75
    @luiscolome75 Před 3 lety

    Very well explained!! Thanks million!

  • @ijazDeveloper786
    @ijazDeveloper786 Před 3 lety

    wow it's awesome i like it i don't know that grid have a powerfull property auto-fit thank u sir

  • @OlivierGrasakaolo
    @OlivierGrasakaolo Před 4 lety

    Excellent stuff, thanks !

  • @sa3858
    @sa3858 Před 4 lety

    This is amazing!!! Thank you so much

  • @bhoot1702
    @bhoot1702 Před 2 lety

    I don't knew this. Thanks 🙏

  • @ozzyfromspace
    @ozzyfromspace Před 10 měsíci

    @00:15 thanks for calling me a junior nooby developer (you're giving me too much credit) 😂. Awesome video bro ✨

  • @user-zn9ss4rr1e
    @user-zn9ss4rr1e Před 3 lety

    Thanks. Great time-saving future.

  • @user-vr1ge8ow5j
    @user-vr1ge8ow5j Před 9 měsíci

    very good explanation video

  • @geebrox
    @geebrox Před 4 lety

    Great tutorial, actually I saw another tutorial in your channel about gallery with such flexible grid display.

  • @mackensonreginaldmichel399

    Very interesting tuto. What are the different sizes and units for mobile? Thanks a lot!!!

  • @hvega7997
    @hvega7997 Před 2 lety

    Will this work as an add on to whatever css styling you already have in your code? What is the proper scope to use this?

  • @braivs
    @braivs Před rokem

    Useful video) I have remained question. How to combine auto-fit with grid proportions?

  • @StrangeIndeed
    @StrangeIndeed Před 3 lety

    good video for a quick refresher c:

  • @lawalsanjo4150
    @lawalsanjo4150 Před 2 lety

    Thank you very very much,
    What have been trying to understand since day one....
    Now, I'm gonna build responsively like a Senior...😂
    I appreciate once again.

  • @swyxTV
    @swyxTV Před 4 lety

    great tutorial!

  • @abishekp.y4736
    @abishekp.y4736 Před 4 lety +1

    Useful video. Thanks

  • @RohithCIS
    @RohithCIS Před 4 lety +97

    The hours I have wasted, Oh my God!

    • @roydiga2669
      @roydiga2669 Před 3 lety +1

      Same here

    • @alexradu1921
      @alexradu1921 Před 2 lety +5

      @@roydiga2669 well, grid's auto-fit is not supported on browsers that haven't been updated since 2020, so.. better use flexbox if you are making websites for clients (yes there are still people there who use PC's from 2008 without any updates)

  • @israelayokunnu7974
    @israelayokunnu7974 Před 4 lety

    This is very productive..Thanks

  • @dragonknight1297
    @dragonknight1297 Před 4 lety

    very awesome stuff, mr. boss

  • @DenisBogdan13
    @DenisBogdan13 Před 4 lety

    Do you save the document every time with CTRL+S? Noticed a few times that the document doesn't auto-update in your videos.
    You need to enable auto-save it in the VSCode settings. I have it set to 2 seconds, I think.

  • @kepelinas
    @kepelinas Před 4 lety

    this changed my life

  • @passucones8894
    @passucones8894 Před 4 lety

    You are amazing. Thanks

  • @mrkbjames3094
    @mrkbjames3094 Před 4 lety

    I've been looking for this all god-dam day! thank you so much "as a newbie to CSS is there a way to apply this to a WordPress theme

  • @isabbot
    @isabbot Před rokem

    Thank you, bro🙂

  • @christerjohanzzon
    @christerjohanzzon Před 4 lety

    Hey! Would you mind sharing a list of your extensions for VS Code? I can't seem to find a good intellisense thingy for html or css...

  • @nnnabbot
    @nnnabbot Před rokem

    Thank you very much

  • @Dtanphat9388
    @Dtanphat9388 Před 4 lety

    great video, thank you very much!!!

  • @SonAyoD
    @SonAyoD Před 3 lety

    great video!

  • @YousefSh
    @YousefSh Před 4 lety +1

    Thanks. I'm less dependant on Bootstrap now.

  • @bundayyolayinka3352
    @bundayyolayinka3352 Před 4 lety +9

    I like how you dissect the web from the CSS POV perfectly

  • @eladioclaudio5860
    @eladioclaudio5860 Před 3 lety

    I don't speak English, but...
    You save my life.....

  • @sidikriders3007
    @sidikriders3007 Před 4 lety

    is it okay now to use grid without the backup styling? I mean do most user use supported browser?

  • @andriilukianenko8106
    @andriilukianenko8106 Před 2 lety

    This is great, I just upgraded my skill in 5 minutes!

  • @anurajms
    @anurajms Před rokem

    thank you

  • @alfonsodelgado5135
    @alfonsodelgado5135 Před 3 lety

    Amazing !!!

  • @user-cx1ul6bu3t
    @user-cx1ul6bu3t Před 4 lety

    This is great 👍🏽

  • @xstrafez_c2017
    @xstrafez_c2017 Před 4 lety

    Very useful, thanks so much again!

  • @Vijay-ih7cv
    @Vijay-ih7cv Před 4 lety

    Thanks 🙏

  • @durvani5262
    @durvani5262 Před 4 lety

    Its very useful

  • @troymitchel4790
    @troymitchel4790 Před 4 lety

    Is it acceptable to use grid and flex nowadays without considering older browser support?

  • @wireinet
    @wireinet Před 4 lety

    Thank you!!! very usefull

  • @ss4717
    @ss4717 Před 3 lety

    aMAZING CONTENT!!!

  • @lucangrobler6377
    @lucangrobler6377 Před 4 lety

    How can I use aut-fit with two different sized columns? As in two different sized columns on desktop and automatically stacked on mobile all spanning the with of the screen.

  • @sandhilt
    @sandhilt Před 3 lety

    Hey, what extension you use to compile sass?

  • @sabirnawaz1304
    @sabirnawaz1304 Před 4 lety +1

    Thanx a lot

  • @jenweatherwax7113
    @jenweatherwax7113 Před 3 lety

    This was perfect, thanks for showing the different ways of doing it! Exactly what I was going through

  • @melulekimhlongo5102
    @melulekimhlongo5102 Před 4 měsíci

    hi there i need help making my nav bar to go to the left and as a drop down, if the screen is not full screen

  • @speedhaak
    @speedhaak Před 4 lety

    Very cool, Cheers!

  • @skmasum4409
    @skmasum4409 Před 4 lety

    Hey gary, please make these video for display=flex as well

  • @DJizz82
    @DJizz82 Před 4 lety +2

    I feel weird now that you mentioned @media being Jr dev..... butttt thank you for a great tutorial!!! Definitely going to use this from now on, always room FOr improvement

    • @stevensavoie856
      @stevensavoie856 Před 4 lety +2

      Media queries are perfectly fine. Just don't use it in place of the right tool. Being a junior dev is also fine, unless you are literally a senior dev. Then by all means, feel weird.

  • @pictureus
    @pictureus Před 4 lety +1

    One thing you didn't take into account is that you might want the grids to show differently if you have multiple resolutions to take into account (mobile, tablet, desktop) etc. It's also more readable using ex. fractions than relying on minxmax etc.

  • @joseflinha
    @joseflinha Před 4 lety

    It's good, but what if I need more padding for .quote element at two columns? With media queries there is more control over behavior... I think... ;-)

  • @jbink6612
    @jbink6612 Před 4 lety

    nice one