Next.js in 100 Seconds // Plus Full Beginner's Tutorial

Поделиться
HTML-код
  • Опубликовано: 13 сен 2024
  • Learn the basics of Next.js in 100 Seconds! Then build your first server-rendered react app with a full Next.js beginner's tutorial. fireship.io/co...
    #react #webdev #100SecondsOfCode
    Next.js Docs nextjs.org/
    Source Code github.com/fir...
    Install the quiz app 🤓
    iOS itunes.apple.c...
    Android play.google.co...
    Upgrade to Fireship PRO at fireship.io/pro
    Use code lORhwXd2 for 25% off your first payment.
    My VS Code Theme
    - Atom One Dark
    - vscode-icons
    - Fira Code Font

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

  • @brintmontgomery8323
    @brintmontgomery8323 Год назад +133

    These 100 sec. videos are pure gold if a person (like me) has never run across the topic at hand.

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

      I'm in my capstone class right now and deciding what languages and frameworks to use in our project we've just been sharing these videos with each other as like a "pitch". never even knew any of them watched these videos but we all do apparently

    • @SaraSohail-en2me
      @SaraSohail-en2me Год назад

      Bruh

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

      @@SaraSohail-en2me xd

  • @codinginflow
    @codinginflow 2 года назад +95

    I'm rewriting my website from vanilla React to NextJS and I love it so far. Many things are much better thought-out.

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

      It is good to see your name crop in the comment section of youtube videos every now and then. :)

  • @mattskelton7471
    @mattskelton7471 3 года назад +1460

    Is it just me, or is it hard to keep up with the rapidly evolving front-end world?

    • @maevshadowsong
      @maevshadowsong 2 года назад +71

      u r not alone

    • @mokv9889
      @mokv9889 2 года назад +320

      Backend dev here who is trying to enter the frontend world. It's a disaster.

    • @jakub7048
      @jakub7048 2 года назад +194

      @everyoneAbove: lol it's reckless to catch up with all these unnecessary technologies, just focus on react and master it

    • @gabrodriguesc
      @gabrodriguesc 2 года назад +26

      @@jakub7048 this

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

      😂😂

  • @kocraft137
    @kocraft137 3 года назад +220

    I just love the "Beyond 100 seconds" stage. You have nice pace in your video

  • @FidelGuajardo
    @FidelGuajardo 3 года назад +125

    Jeff has a special talent for teaching and if he does his own videos, then he also has the skills for doing excellent videos!!! I consider him to be one of my top 5 all-time best tech teachers.
    Thank you, Jeff.

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

      who are some of the others in the top 5?

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

      PS. Jeff's videos are awesome

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

      @@LouisDuran I gotta say, Web Dev Simplified (Mainly JavaScript) and Kevin Powell (Only makes videos on CSS) both make really good educational programming videos. Highly recommend them if you haven't seen them already.

  • @nate1988
    @nate1988 2 года назад +58

    Seems like I'm going to be doing at my React projects as Next.js now. I really can't see a reason not to default to using it. Great video -- it's been nice coming back over the months and going from confusion to understanding.

    • @david_sanchez
      @david_sanchez Год назад +6

      1 reason to not default to Next is when building something like a CRM. Web indexers don’t need (and shouldn’t have) access to the private data in a CRM web app. In cases like this, a client-side React app is perfectly sufficient.

  • @SuprunAlexey
    @SuprunAlexey 3 года назад +307

    Next js is the best way to create fast site in a few hours. You need just basic knowledge of JavaScript and react. 💡💡💡

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

      Какими судьбами ?

    • @hijazi479
      @hijazi479 3 года назад +36

      Not basic but intermediate level knowledge of react

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

      Nuxt.js: am i joke to you

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

      Best is highly subjective, especially since text files would work just as well for Static Sites...

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

      Is there a reason to learn Gatsby over Next?

  • @muhammadsami479
    @muhammadsami479 3 года назад +407

    Rust in 100 seconds 🔥🔥

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

      Yes!

    • @Fireship
      @Fireship  3 года назад +169

      Someday, I've been slowly learning Rust for the past 2 years.

    • @architbhonsle7356
      @architbhonsle7356 3 года назад +11

      Bruh Rust... In 100 seconds.... 🙂

    • @Nexus-rt1bm
      @Nexus-rt1bm 3 года назад +1

      YESSSS

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

      Hahahahaha good one mate 😂

  • @codeSTACKr
    @codeSTACKr 3 года назад +282

    🔥🚀

  • @juancarlosqr
    @juancarlosqr 3 года назад +20

    Joining fireship for the Next.JS & Firebase course!!! 🔥🔥🔥 Can't wait!

    • @Anto-xh5vn
      @Anto-xh5vn 2 года назад

      @@godwinebikwo6544 I would be surprised if anyone actually helped you :)

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

    Short, rich, straight to the point video ! just what I needed, thanks !

  • @MaxProgramming
    @MaxProgramming 3 года назад +39

    What a surprise I got! I requested it and I got it! Thanks Fireship!

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

    Started learning JS about a month ago. I understood about 20% of this video and stopped about half way. Still have a few weeks left in my course then a few more weeks more to complete my react course. This is just a reminder to myself to see if understand more next time I watch this.

    • @duppy404
      @duppy404 Год назад +4

      Well it's been 8 months do you understand the tutorial now?

  • @NabilTharwat_
    @NabilTharwat_ 3 года назад +11

    I'm about to make a video (in Arabic) about building a Next blog and this just motivated me more! Informational and straight to the point, as always!

  • @Felipe-pb9gu
    @Felipe-pb9gu 3 года назад +60

    it would be great if you include SWR in this course, I think is a good match with next/firebase, makes caching and other things a lot easier. Vercel hosting is a nice feature too.

  • @rosecancode9455
    @rosecancode9455 3 года назад +6

    I feel like I just learnt a new tech. Thanks so much. I just heard next today and I already have a comprehensive understanding of it after watched this.

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

    I find this guys voice highly therapeutic, for some reason its enjoyable...

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

    Best few minutes of my life.

  • @tymcfarland8158
    @tymcfarland8158 2 года назад +15

    Only devs would put a "//" in their youtube video title...

  • @GaelGendre
    @GaelGendre 11 месяцев назад +3

    Now it has changed with Next.js 13: routes (4:03) and dynamic route (5:15) check the docs

  • @danielcallaghan6892
    @danielcallaghan6892 2 года назад +39

    im drunk and this makes no sense ! woooooooooooooooooooo!

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

    we started from client-side rendering (static pages) to all server-side with PHP to all client-side with JS frameworks and now back to server-side rendering

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

    Best summary ever

  • @tylersustare
    @tylersustare 3 года назад +6

    Love it! Ruby on Rails in 100 seconds 💎

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

    The first time I heard about next.js was YESTERDAY, and TODAY you bring me this video, I'm starting to think you really read some minds

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

    Impatiently waiting for the full course 😃

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

    Was looking for this and your video dropped in notifications.

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

    Been watching Nextjs tutorials all over the internet but this is by far the best I have ever seen 🔥🔥🔥🔥

  • @LongJourneys
    @LongJourneys 3 года назад +54

    For me the biggest reason I use Firebase is authentication. It was a bit of a pain to figure out how to keep authentication persistent on page reload with Vue/Nuxt; so if you could do a walkthrough on that with Next, that would be cool.

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

      well i use angular and to keep authentication persistent i would save the user token on the browser and everytime the user refreshes the page i would ask the server to get the current user from this token and all would work fine in my experience ofc

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

      have they fixed auth with Vue/Nuxt now ?

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

      @@stunna4498 Where do you store it on the client side? Cookies or storage?

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

      @@danielchettiar5670 yeah i store the token in the storage of the browser( client side). Everytime you make a request to the api u send the token. If the server responds with a 401 (Unauthorized) i redirect the user to the login page.

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

    why is the folder structure of my next app completely different? has nextjs really changed that much in 3 years?

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

    next.js and firebase would be a candy even if it is a simplest CRUD, I'd definitely buy it

  • @911madza
    @911madza 3 года назад +3

    Talking about quality Fireship produces 👌
    Vercel should consider embedding this on their Nextjs landing page 💯💯

  • @SamFromaway
    @SamFromaway 3 года назад +9

    Great video as always. What I would be interested in a course is to learn how the hydration with next exactly works. Especially in regards to the script __NEXT_DATA__ and how to integrate css libraries like Material UI and Chakra. 😁

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

      Hydration is also weird when dealing with realtime firebase data, I'll cover that in the course

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

      @@Fireship Cool thanks :D

  • @siddhubhai2508
    @siddhubhai2508 2 месяца назад +1

    Next js is really god level framework for react apps I will use that I'll my projects

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

    Exactly what I needed! I just started a project with Next.js yesterday

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

    Thanks for putting up together this video I learned the entire concept in less than 12 mins while I was on Next.js website for hours trying to understand it...smh

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

    I just made a letterboxd clone with Next.js and it's pretty cool, though I stored a JWT in the client side, so I stupidly couldn't use most of the SSR functionalities, so the best way yo do authentication with Next.js is to have something like a JWT in a cookie so you can fetch user information during the SSR process.

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

    Switched from Next.js to Sapper/Svelte and never looked back. It gives me the giggles when I see React / React-based frameworks tutorials lately...

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

      Tell me more

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

      Giggles? When Sapper is about to be deprecated. Yep, giggles.

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

      @@exactzero About to != is deprecated. I am still using it until Svelte Kit is ready and stable.

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

      @@exactzero React is also about to be "deprecated" by other JS libraries in some point in time, but that doesn't stop you from using it, does it?

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

      @@StEvUgnIn I like those more because I am more productive when compared to React. Also, they provide smaller bundles and they have the "use the platform" approach, so there is no "Virtual DOM diffing", making apps feel faster while running.

  • @1_PieceOfCode
    @1_PieceOfCode Год назад

    2:24 I was not going to try it now but this line did it for me. love you work man

  • @djlee0721
    @djlee0721 3 года назад +6

    Looking forward to the course! Take my money!

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

    Now we need the same but with nuxt.js ;)

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

    Like the videos, just want to add,
    SSG can be used for highly dynamic sites, see the entire genre of Jamstack development but basically you can use API calls to display new data on static pages. (static sites could also use js to do animations and 'non static' stuff)

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

    im starting to fall in love with this channel

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

    Love the icon theme you're using. Which is it?

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

    Thanks for the tutorial, well explained and straight forward, helped me a lot since I just started working on web development

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

    Thanks, Man...
    That was a quick and crisp introduction.
    💕💖💕💖

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

    Lol, that was a funny little trip from server-side to client-side over the last 10 years...only for kiddos to go back to big daddy in server land!

  • @Mr.Andrew.
    @Mr.Andrew. 3 года назад +5

    I'd be interested in finding out how to serve part of a site in next and another part in React. As for modern webapps in a privacy aware era, there are many things you'd want to exclude from web crawlers without destroying seo optimization.

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

    Question: Next.js + React ≈ Angular Universal?

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

      Yes, that's about right

  • @Phoenix-jh7gu
    @Phoenix-jh7gu 3 года назад +2

    a full stack project using Nextjs, tailwindcss, react-query, RestAPI, Mongodb

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

    This is alot better than 2 hour courses !

  • @ranaakhil
    @ranaakhil 3 года назад +14

    Hey. Love your work. Great videos.
    Can you please do one on Nest.js
    It's a really underrated node framework.

    • @Fireship
      @Fireship  3 года назад +11

      Nest is awesome, I'll cover it more in the future

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

    100 Seconds is the best quick burst tutorial structure on the internet.

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

    Awesome! I am a pro subscriber of fireship & the only thing I havent seen you touching till now is, Testing :) .. Any chances of seeing a full pro course in angular testing? :D That would be invaluable !

  • @maacpiash
    @maacpiash 3 года назад +14

    "Thanks for watching, and I will see you in the *next* one."

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

    Help me out here. We are going back to server side rendering? Generating static HTML and giving it to the client? So is this similar to how we built web apps like a decade ago?

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

    Great intro to the framework. Thanks!

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

    Finally you are going back to Ruby on Rails with extra steps... Many developers moved to React and client side, just to move again to server side rendering with Next.js. Why not just use a traditional framework like Rails or Laravel? I don't see any advantage

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

    This is amazing, for experience developer we just need short intro, this was so helpful

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

    No way, I have been digging into this the past week. Would love NuxtJs as a Pro Course.

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

    Nuxt.js next? :D

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

      I would wait for Nuxt 3 ☺️

  • @jayanths1221
    @jayanths1221 3 года назад +185

    Three Js in 100 seconds

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

    Loving the 100s + tutorial vids!!

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

    NestJS Next please. 🦁❤️

    • @rohankapur5776
      @rohankapur5776 3 года назад +7

      Had to read this one twice despite knowing both Next and Nest lmao

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

      nestjs is awesome framework !

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

      I will love to nestjs as well

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

      @@rohankapur5776 At least you don't use Next, Nest and Nuxt...

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

      @@PhatOof 😂 I could NEVER

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

    Best new year's gift ever

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

    Thanks i knew about Michael Hill! He was my professor in Oxford and told us FBC fund!

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

    I really Angular, but you Jeff took some of that apprehension that I had for React. Now I can at least work with both and now I feel like I can tackle next.js too.

  • @TamDNB
    @TamDNB 3 года назад +61

    First time I've learned a thing before you did a 100 secs...oops

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

    Literally after deploying my next js app sweet timing!!

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

    Haha "I'll see you in the NEXT one" nice one!

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

    perfect! after dabbling with wordpress, one thing i thought was actually an improvement on react was how the server created the page before sending it out.

  • @coolk2000
    @coolk2000 3 года назад +7

    This was a great tutorial, but one question I have is how do you implement components with it? Are pages the only way to lay out UI? Is there less encapsulation with Next? An example would be if I want a specific UI feature to be shown on multiple pages, and it has its own functionality, do I have to Implement a copy of this on each page or can I create 1 component, import it, and render it on multiple pages?

    • @Fireship
      @Fireship  3 года назад +6

      Good question. Each page needs a `default` export, but you can create a top level directory like `lib` to share in multiple pages. So no, you don't have to duplicate implementation details.

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

      You can create a component that holds (just an example) a footer and a header. In order to have these on every page you go to the _app.js file in pages and wrap your app content in that component. One single import and every new page will now have that component containing a footer and a header.

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

      You work the same way as in regular React by creating components that you can import anywhere.

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

    I don't think I know enough about each component to be excited about this.

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

    Would be interesting to hear a comparison with Nuxt

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

    dude i love you so much, you explain soooo well

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

    I’m actually planing to learn NextJS for my next project, but I’ll wait for your course, because the application will use firebase as back end and server side rendering on front end

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

    The best web development framework out there!

  • @HamaadSiddiqui
    @HamaadSiddiqui 3 года назад +11

    Elixir in 100 seconds 👀 ? 🔥 🔥

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

    First time someone properly explained client side rendering...

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

    That's what I was looking for. Thanks so much.

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

    I've written my own frameworks until now. This actualy is close to what I've implemented. I've never used React, Vue nor Angular. I will give this a try the next couple of days.

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

    So SSR is exactly what a lets say php server would do right?

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

      The big difference is how it transitions (or hydrates) from server to client. Only the initial page load is rendered from the server.

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

    Thanks Jeff. How does implement real-time data fetching in next with firebase? Also, how do we deal with cloud functions? And would deploying to vercel be the better choice?

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

    thank you for this clear and easy to understand video, i hope i can see nextjs internationalization and nextjs for eCommerce in your courses

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

    I see what you did there at the end, I'll see you on the Next one. 😀👍

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

    I watch every videos on YT at 2x speed. But there should be a 0.75x speed to watch fireship.io videos. Anyway, 100 seconds never disappoint.

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

    In regards to performance, is Next comparable to Svelte?

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

    MANNNN!! you are doing amazing, keep it

  • @hassan_codes
    @hassan_codes Год назад +5

    ...so basically Next.js is PHP you can write in Javascript. Got it!

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

    SSR is easily the most overly complex and overly expensive thing pushed by hype.
    I rather use lambda edge or cloudflare workers to alter the metatags of the index.html file, no need to render everything server side and manage tons of complexity around it.

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

    amazing work, as always - thanks Jeff!

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

    awesome video. thank you!

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

    love the videos. kind of curious....do you think a regular SPA app made in the vue-cli, CRA, or angular-cli is a way of the past? Like would there be any reason to keep making those? Nuxt/Next and the SSR wave I've been trying to understand, but keep going back and forth if this like makes traditional SPAs obsolete.
    Especially in like internal apps where something like SEO you don't care about.

  • @perfectambience108
    @perfectambience108 19 дней назад

    4:35 he really writes "hi mom". 🥰

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

    Now I know which is my next course. I started one on Udemy, but I'll switch to this one for sure :)

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

    thanks, very informative and time efficient way of learning :)

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

    Great nextjs video!

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

    the more react stuff, the more useful channel :)

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

    We use next.js for our projects for more than 2 years now and I can't recommend that more.