Navbar CSS Tutorial: 3 Ways to Create a Navigation Bar with Flexbox

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

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

  • @SpeakDrumz1
    @SpeakDrumz1 Год назад +19

    15 min video and I stayed all day long doing this. Thank you! For sure helped a lot.

  • @FRONTRUS
    @FRONTRUS 4 года назад +12

    This channel should be rearward!
    They post tutorial videos for free and without any advertisements! 😍😍😍😍

  • @matthewborkowski5313
    @matthewborkowski5313 2 года назад +189

    Great tutorial. Loved the pacing. Perfect I think for someone that already understands a bit about CSS and HTML, no BS, just content, looks great too.

    • @Skillthrive
      @Skillthrive  2 года назад +2

      Glad you enjoyed it!

    • @jgappy
      @jgappy 2 года назад +5

      Bro...u could have just used Emmet abbreviation ! for boilerplate

    • @d.o.nmuzic3802
      @d.o.nmuzic3802 Год назад +1

      Yup! Pace is perfect! End result is amazing. And I love that he explains what the code is doing.

  • @saurabhdaswant7833
    @saurabhdaswant7833 3 года назад +8

    Thank you for the tutorial man before waching this i was not knowing what does
    1 inline-block
    2 display: flex
    3 justify-content
    etc......
    i was really searching this type of content
    thank you so much

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

      Inlineblock means left and right both side we can handle in margin padding etc

  • @rathernotdisclose8064
    @rathernotdisclose8064 4 года назад +73

    in visual studio code, you don't have to select a line to copy it, just place your cursor at the end of the line without selecting the content there, and hit CTRL C (or x for cut) and it'll be copied. Or, in your case whatever the key is on mac.

  • @olawalevictor134
    @olawalevictor134 Год назад +10

    Scrolling down my feed and found this video today. One of the videos that helped me back then when I was a beginner. Thank you.

  • @nehat7924
    @nehat7924 4 года назад +79

    Thanks very much mate, this is exactly what I was looking for !!!

  • @bchinggisi
    @bchinggisi 4 месяца назад +1

    bro Your helping millions of people around the globe i really appreciate it and i'm actually Learning From your Videos Your have Earned a loyal Subscriber

  • @mshimanshu1000
    @mshimanshu1000 3 года назад +8

    YOU JUST SAVED A LIFE MAN !!!!!!!!!!

  • @liverpoolkelly7
    @liverpoolkelly7 2 года назад +2

    That order property is a godsent! I was banging my head for days trying to create a centre logo navbar

    • @Skillthrive
      @Skillthrive  2 года назад

      It really is. It's almost a magical CSS property.

  • @mhhamzaedits
    @mhhamzaedits Год назад +3

    Thank you sir ❤
    I am from India 🇮🇳

  • @zero0bb
    @zero0bb 3 года назад +2

    this is weird basic stuff that I never knew could be implemented like this, nice.

  • @FernandoHernandez-jp4gt
    @FernandoHernandez-jp4gt Год назад +5

    Thanks for this! Seems so complicated at first but after a few replays I got the gist of the design and now kinda know it myself!

  • @dariomasip
    @dariomasip 5 лет назад +4

    The moviment of the cursor with that blur is amaizing!

    • @JulianColeman03
      @JulianColeman03 5 лет назад

      It's because he's using a high refresh-rate monitor

  • @manarahmed1917
    @manarahmed1917 3 года назад +4

    Thank you so much I appreciate it when people actually explain what they are doing in css!

  • @supportex2228
    @supportex2228 5 лет назад +9

    Very nice mic quality and clear explanation of what did you do in this tut. Looking forward for more!

  • @deadlysilence5511
    @deadlysilence5511 3 года назад +12

    Great tutorial! Funnily enough, I use Montserrat too and have used it in past projects, I was just searching around for some good navbar tutorials. Keep up the good work!

    • @developer2
      @developer2 2 года назад

      Same man, Montserrat just genuinely looks good especially with websites!

  • @gorsama-2190
    @gorsama-2190 5 лет назад +72

    Wow your videos are so good definitely better that those with music, love your content keep it up👍♥️

  • @leandrodossantos9160
    @leandrodossantos9160 4 года назад +21

    Thanks dude, I was looking for this kind of structure!

  • @Loki_Dokie
    @Loki_Dokie 2 года назад

    Thanks bro, i know it seems simple, and I'm pretty proficient with all else html and css, but navbars have just given me hell for some reason. Thanks, you've cleared it up for me.

  • @dannyjdhall
    @dannyjdhall 3 года назад +15

    Just found this tutorial. Thank you. I love the modern look, and this helped me solidify my knowledge in creating navbars.

  • @AppOasis82
    @AppOasis82 4 месяца назад

    truly clear explanation and straight to the point. Looking forward getting this good at coding.

  • @vencalysek7847
    @vencalysek7847 5 лет назад +10

    Amazing video, in 15 minutes taught me more than cod*cad*my css course!
    THANK YOU so much!

    • @Skillthrive
      @Skillthrive  5 лет назад

      That’s awesome to hear, Venca!

    • @vencalysek7847
      @vencalysek7847 5 лет назад

      @@Skillthrive If i may, can I have one question?
      How to make fixed navbar while scroling? i used position: fixed, and then all 3 sections came together. Somehow it overwrites justify-content
      Thanks for help :))

    • @Skillthrive
      @Skillthrive  5 лет назад +1

      @@vencalysek7847 It's actually pretty easy using position: sticky. Checkout this link with the code: codesandbox.io/embed/static-72sod
      I added comments in the css of what I changed.

    • @vencalysek7847
      @vencalysek7847 5 лет назад

      @@Skillthrive Thank you very much! :)

  • @ericgraham5201
    @ericgraham5201 2 года назад

    Finally a header without 20 div tags!

  • @skully8767
    @skully8767 4 года назад +174

    does he actually memorize all those hexa.. color codes

    • @hassansiddiqui428
      @hassansiddiqui428 4 года назад +20

      With time you learn

    • @jer461
      @jer461 4 года назад +30

      He may use those colors frequently so he memorized it already. There's a million of hex codes and no one in the world has memorized them.

    • @PhilBot4OOO
      @PhilBot4OOO 4 года назад +16

      Nah pretty sure you can hear his voice shif to a reading tone rather than recalling naturally from memory!

    • @j._rom4597
      @j._rom4597 Год назад +1

      Nope

    • @mbonisimtunzi
      @mbonisimtunzi Год назад +3

      You surely remember you favorite colors

  • @kkyrwh6772
    @kkyrwh6772 3 года назад +1

    These navbars look awesome...sephora uses such

  • @aalayer2834
    @aalayer2834 4 года назад +4

    Keeping things nice without any bootstrap related stuff! Noce tutorial mate

  • @ngire
    @ngire 4 месяца назад

    i've searched for 2 weeks! Thanks man.

  • @usama57926
    @usama57926 5 лет назад +29

    amazing design and explanation

  • @haileymae42
    @haileymae42 Год назад +1

    Thank you so much! This really helped me for my major project

  • @christiancolewan
    @christiancolewan 3 года назад +4

    Im making a portfolio and i was having trouble in the navigation bar
    this tutorial is exactly what i needed.

    • @許潤璋
      @許潤璋 2 года назад +2

      I'm glad I'm not the only one.

  • @solme8577
    @solme8577 2 года назад +2

    Just finished with the tutorial. Simple yet effective. Thank you sir!

  • @velocikitty9300
    @velocikitty9300 2 года назад +8

    Great content. I was able to follow along and even correct my mistakes when it didn't turn out like yours. I'm a complete beginner so I can't say it is beginner friendly (for my level at least) since I was just following along and didn't understand what I was putting in. But that's because I'm a level 1 out of 3 beginner. If you're in the mid-range beginner (if that makes sense) I think you'll be able to pick up on this really well since I did with my complete lack of knowledge. But this was great to learn. Once I get the hand of the basics, I think I'll be able to follow along and understand more completely. Thank you for this content.

    • @sugoish9461
      @sugoish9461 Год назад

      How's it going for you? :D

    • @DrEggCake
      @DrEggCake Год назад

      if@@sugoish9461if u want i can help u both with code

  • @najimali32
    @najimali32 4 года назад +2

    Do you know what the best things about you, you know what you doing & you explain it while coding, that the things I was looking for. Thank you so much!!.

  • @barbaraquintero3068
    @barbaraquintero3068 2 года назад +3

    Does everyone knows why can't I set the logo to the right side? with margin-right:auto; I don't understand
    EDIT: If this happened to you, in my case, I've put the logo into a tag, you have to put the margin-rigtht to that class and not for the logo.

  • @kasuniversity
    @kasuniversity Год назад

    Wonderful. I learnt new ways of doing the Nav bar.

  • @rjc4200
    @rjc4200 3 года назад +21

    Short, Crisp and to the point. Thanks for this video. Keep it up :)
    It also reminds me why we usually tends to use different CSS framework/s just to avoid writing so many lines of code just for a simple nav bar design.

    • @contraspower6302
      @contraspower6302 3 года назад +1

      In the html why did he put the img inside the header? Why can't we put img under nav.

    • @sidrashawaj
      @sidrashawaj 3 года назад +5

      @@contraspower6302 because we want the header to be divided into 3 parts, basically (logo, links and button). So if u include the img under nav, you can't have the logo set anywhere far from the nav elements.

    • @contraspower6302
      @contraspower6302 3 года назад +1

      @@sidrashawaj Thanku brother 🙏

  • @alvarezgamers
    @alvarezgamers Год назад +2

    You have an extremely effective way of explaining stuff. You got a new sub! :)

  • @mrCetus
    @mrCetus 2 года назад +5

    Thank you for this tutorial! I made all three and changed the CSS to have variables at the top to make it more customizable and put the navbar into a div element. I also make the image a link! So if I ever need this for a project I can just insert the code to my page.

  • @bhoot1702
    @bhoot1702 3 года назад

    Amazing video. I was frustrated so much but this video helped me

  • @spacelama666
    @spacelama666 5 лет назад +27

    Just what I needed, keep em coming!

  • @teched7467
    @teched7467 4 года назад +2

    Thanks really helpful I understood all the code and now I know how to create menus and buttons

  • @naitikkathiriya
    @naitikkathiriya 3 года назад +24

    It's so simple stylings and HTML formatting for header class building.. thank u so much the maker! Really helped. And video ending Subscribe button neon effect u make so cool✔️✨

  • @BTFezzer
    @BTFezzer 3 года назад

    i learnt more from this then i did from an hour long tutorial on css thanks

  • @TheSpiralnotizblock
    @TheSpiralnotizblock 4 года назад +3

    bro you actually saved my ass

  • @TheChosen0791
    @TheChosen0791 3 года назад

    Great tutorial, now I am starting to understand Flexbox.

  • @adamvalli6233
    @adamvalli6233 2 года назад +6

    I feel like joe rogan is teaching me flexbox

  • @muhammadzafar2470
    @muhammadzafar2470 4 года назад +1

    very smooth and smart way of coding . i like it too much and very helpful for me .

  • @mohamedsuhailirfankhazi6628
    @mohamedsuhailirfankhazi6628 2 года назад +3

    Great tutorial! Simple to follow and to the point. Very helpful.

    • @Skillthrive
      @Skillthrive  2 года назад +1

      Glad you found it helpful! Be sure to check out my new stuff, too. 😊

  • @colinabel4051
    @colinabel4051 3 года назад

    cheers been using this as a reference for a much more complicated header and its dumb helpful

  • @forhadrh
    @forhadrh 4 года назад +3

    Wow! Such an awesome nav with such simple code.. Why I don't think that way -_-

  • @umangternate
    @umangternate 3 года назад

    I learned many new things in this video, especially, order...

  • @brunopeselli3662
    @brunopeselli3662 5 лет назад +9

    On point! just what I needed, keep it up 🤘🏼

  • @vaibhavborkar9476
    @vaibhavborkar9476 3 года назад +1

    Thankew Thankew Thankew Thankewwwwwww sooo much......u helped me alot thanx brother.

  • @dimtodim
    @dimtodim 5 лет назад +29

    great job mate :)...i know all that stuff but i forget detail :) nice to fresh memories...

    • @Skillthrive
      @Skillthrive  5 лет назад +10

      Thanks! It’s crazy how fast we can forget things. 😅 Refreshers are always nice.

  • @Narceologist
    @Narceologist 2 года назад

    Thank you so much for this, just started learning and I was so stuck trying to make a navbar.

  • @jackroses1064
    @jackroses1064 3 года назад +3

    Exactly what I needed 😃

  • @jamshaidmalik463
    @jamshaidmalik463 3 года назад

    This video is really helpful for me thanku sooooo much channel owner❤️

  • @jaydenmoon1165
    @jaydenmoon1165 3 года назад +5

    Wow this was presented very clear and concise - wonderful video - I learned a lot, thank you :D

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

    Found this in my feed after making the exact same thing yesterday! 😮

  • @Floriskoek
    @Floriskoek 4 года назад +3

    Damn awesome. To the point, clear and explained what you are doing. Thank you so much!

    • @Skillthrive
      @Skillthrive  4 года назад +2

      Thank you! Glad you enjoyed it.

  • @jackfrost8969
    @jackfrost8969 3 года назад

    This is golden content.

  • @eugenechernov837
    @eugenechernov837 5 лет назад +4

    Great professional tutorial. Thank you!

    • @Skillthrive
      @Skillthrive  5 лет назад +1

      You’re welcome Eugene! Be sure to check out the new one I posted today about how to make the navbar mobile friendly.

    • @zReeMaKe
      @zReeMaKe 4 года назад

      Skillthrive trying to find this video.

  • @hagahaguusha2691
    @hagahaguusha2691 Месяц назад

    Thank you for reaching me this tutorials I've been searching such this course
    Thanks again 😊😊

  • @anuj7286
    @anuj7286 5 лет назад +3

    Thanks for making this tutorial 🙂

    • @Skillthrive
      @Skillthrive  5 лет назад +2

      You're welcome! LMK if you have any questions. 😁

    • @anuj7286
      @anuj7286 5 лет назад +1

      @@Skillthrive can u make this responsive?

    • @Skillthrive
      @Skillthrive  5 лет назад +1

      It’s possible, I just didn’t do it in this course bc I thought it would make the video too long.

    • @Skillthrive
      @Skillthrive  5 лет назад +1

      Keep an eye out for a video on how to create a responsive menu though. I might do it this week.

    • @Skillthrive
      @Skillthrive  5 лет назад +3

      Hey, I just published a video on how to make this design mobile friendly: ruclips.net/video/WxQZsN6LICM/видео.html

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

    Thank you for your generous sharing. It's really helpful

  • @polartitangaming1887
    @polartitangaming1887 4 года назад +72

    I kind of wish we got to see more of how this looks on multiple browsers. Such as mobile, tablet, etc. I can make great NAV bars, but designing something that works on other things is hard to do for me.

    • @sarfarazstark
      @sarfarazstark 2 года назад +2

      why not check in inspect

    • @edris9664
      @edris9664 Год назад

      use media queries (@media) set max-width: (however many pixels); for optimizing for desktop sizes. if you're optimizing it for mobile use min-height. @mustangbs9897

    • @billzade8158
      @billzade8158 Год назад

      You can also adjust paddings, margins, positions, etc...based proportionally instead of by pixel as well

    • @atlantic_love
      @atlantic_love 10 месяцев назад +1

      who cares about those platforms?

    • @billzade8158
      @billzade8158 10 месяцев назад +1

      @@atlantic_love some do.

  • @vfxjmb
    @vfxjmb Год назад

    nice tutorial bro
    ive been struggling for a while trying to learn css flexbox

  • @MartinoxxHD
    @MartinoxxHD 5 лет назад +4

    So the "li:nth-child(1)" value it's used to give a style only to the first , right?

    • @Skillthrive
      @Skillthrive  5 лет назад +1

      Yep! 🙂

    • @sciencecompliance235
      @sciencecompliance235 5 лет назад +1

      You could also use "first-child". I forget the specific syntax. I think it's first-child, but you'll want to verify that.

  • @orincywhytedesigns
    @orincywhytedesigns 3 года назад

    Ahhhhhhh the last example was so helpful!!!! Thank you

  • @nandhinianand2786
    @nandhinianand2786 5 лет назад +3

    Thank you so much!!!

  • @ajogburn96
    @ajogburn96 Год назад +1

    I love this tutorial. I think the Joe Rogan voice definitely helped

    • @Skillthrive
      @Skillthrive  Год назад

      Lol these Joe Rogan comments get me 😂

  • @trungphan3504
    @trungphan3504 5 лет назад +3

    it's really nice, thank you

  • @СерёгаСТАЛКЕР-х7в
    @СерёгаСТАЛКЕР-х7в 3 года назад

    Thank you, you did not miss anything and took into account.

  • @pederrudi6352
    @pederrudi6352 4 года назад +10

    my logo kind of appears ontop of the navbar? how do I make it be next to it?
    edit:
    my logo img was inside . it was fixed when I placed it before

  • @adamoceallaigh2267
    @adamoceallaigh2267 5 лет назад +64

    Hey man , great tutorial . Just wondering do you know that the option HTML : 5 under the boilerplate one that you added with the extension in VSC achieves the same result as what you get at 2:14 and you don't have to delete the comments . A quick shortcut with emmet to activate this is - just type ! and press tab at the start of the html page and you get exactly what you need . Just letting you know . Great tutorial though , helped me a load , thanks . Keep it going 👍

    • @adamoceallaigh2267
      @adamoceallaigh2267 5 лет назад +11

      Emmet is an unreal shortcut that comes pre-installed with VSC , you can also make an ordered list with three li a tags very quickly by typing ul>li*3>a and pressing tab and there you go ! :)

    • @Skillthrive
      @Skillthrive  5 лет назад +18

      Hey, Adam. Thanks for the kind words. I actually found out Emmet come pre-installed after posting this video, but I honestly don't use it much. I need to practice using it more, though.

    • @Wake_up_to_reality_143
      @Wake_up_to_reality_143 Год назад

      @@Skillthrive good thought

  • @DevRobinHossain
    @DevRobinHossain 4 года назад +1

    Very very helpful man.........
    Thanks for sharing this content.

  • @TheTonyMan
    @TheTonyMan 3 года назад +3

    Good tutorial, thanks! But there is a slight correction. Button and link are different entities, it makes no sense to place a button inside a link.

  • @akashgillella
    @akashgillella 3 года назад +1

    Very nice video man, thanks. It was so simple mannn!

  • @Skillthrive
    @Skillthrive  5 лет назад +8

    Tutorial on how to make this navbar mobile friendly: ruclips.net/video/WxQZsN6LICM/видео.html
    Updates [ Aug 2019 ]
    It's not best practice to wrap a button with an a tag. Instead, just give the a tag a class and style the link to look like the button.
    Also not a good idea to set background color on all elements like I did because you'd more than likely run into some unexpected styling if you were using this for your website.

    • @sougataghar1179
      @sougataghar1179 5 лет назад

      instead of setting margin to auto , cant we also set justify-item to flex-start ?? for the logo i meant, soo it goes to left all the way

    • @erickhilario6217
      @erickhilario6217 5 лет назад +2

      @@sougataghar1179 but you will have that use the property flex-direction: row-reverse and back to same

    • @gandalfshandle
      @gandalfshandle 5 лет назад

      What color theme is installed in your VS code?

  • @sejutybarman9870
    @sejutybarman9870 3 года назад

    Thanks a lot..now navbar is clear to me.

  • @gurulovearthi
    @gurulovearthi 3 года назад +4

    How to make responsive bro please tell me

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

    I love this tutorial, wonderful lesson❤

  • @Skillthrive
    @Skillthrive  5 лет назад +4

    ⚠️ October Updates (Code reflected in course files)
    • Mobile navigation added to all examples (in-depth example here: ruclips.net/video/WxQZsN6LICM/видео.html
    • Imported the Google Fonts in the head section of the index.html file instead of the CSS file
    • Removed the button that was being wrapped by the a tag and moved the button styles into .cta class styles
    • Removed the global background color (sorry for the confusion, this was a bad idea in hindsight) and moved it into the header styles

    • @Skillthrive
      @Skillthrive  5 лет назад

      @Woohui Kim Just updated. Thanks for letting me know.

  • @michiakbar2345
    @michiakbar2345 Год назад +1

    you really a great teacher!Thank you!

  • @Fleshlight_Reviewer
    @Fleshlight_Reviewer 4 года назад +4

    note to self: use this

  • @devisistech
    @devisistech 5 лет назад +2

    U mak learning very easy for some of us...

  • @AllyG1967
    @AllyG1967 5 лет назад +4

    Great video, thanks. Newbie question - Right at the beginning, why did you name your folders with an underscore.

    • @Skillthrive
      @Skillthrive  5 лет назад +8

      So your folders will automatically be alphabetized, but if you put a _ in front of the word it will alphabetize those first. So I like to put my main folders with a _ and less important ones without. You can even add another _ to the existing one and it will start over with those alphabetized first. Kinda like this:
      __a
      __b
      __c
      _a
      _b
      _c
      a
      b
      c

  • @you39tubeable
    @you39tubeable 5 лет назад +3

    Did not know about the order property, thanks

  • @ifailed6935
    @ifailed6935 2 года назад

    you're so good you make it look so easy

  • @ronnelmacompas1647
    @ronnelmacompas1647 2 года назад

    This is great navbar. Thank you!

  • @Vanegasssssss
    @Vanegasssssss 2 года назад +1

    Simple, quick, easy and beautiful, like

  • @rollanjame2885
    @rollanjame2885 Год назад

    The besst solution..... Thanks in advance...

  • @Joel.Invictus
    @Joel.Invictus 4 года назад +1

    Very Helpful demo, bro. Thanks a lot!

  • @facundocruz8133
    @facundocruz8133 2 года назад +1

    Nice video bro,
    greetings from Argentina 💙🤍💙

  • @tomc0240
    @tomc0240 2 года назад

    This is excellent. Clear and concise

  • @maxsaparaliev4027
    @maxsaparaliev4027 4 года назад

    Holy, man. Thanks, i've just learned that i can order elements in a flex container. Awesome, ty again man.

  • @byzeezus
    @byzeezus 3 года назад

    THANK YOU IVE BEEN LOOKING SOOO MUCH ON HOW TO DO THISSS

  • @justtechgyan3571
    @justtechgyan3571 Год назад +1

    Great video and very helpful for beginner 💯

  • @hilmialmuhtade8523
    @hilmialmuhtade8523 3 года назад

    its beautiful layout and styling. and i hope you will make this responsive, thank you. salam from Indonesia 😊