How to Install Next.js
Zenva
ACCESS the FULL COURSE here: https://academy.zenva.com/product/full-stack-web-development-mini-degree/?zva_src=youtube-fullstackmd
TRANSCRIPT
What's up everyone, and welcome to our tutorial on installing Next.js. Before we can learn how to use it, we should probably obtain the software and get ourselves set up with a new practice project. So what do we need to get started? We can think of these as being prerequisites. For starters, we'll need a text editor. This is gonna be some way to write code. I'm gonna use Sublime Text, although feel free to use whichever one works best for you, that's notepad or notepad plus plus or sublime, either one works. We'll need some way to run Unix commands as well. For those of you who using Mac or Linux, this'll be the terminal and for you Windows users, this'll be Command prompt or PowerShell. And we'll also need Node.js functionality installed. So I'm kind of assuming you have all three of these things. If not, then please get yourself set up with them before continuing. How do we then go about installing Next.js? Well, one of the best things about this is that there's actually no need to download any bulky packages. We simply start a new npm project, install react functionality through a couple of command line commands, and then we add a script to package.json and then finally, create a pages directory and that will be the project fully set up. So what are we going to do in this tutorial here? Well, we'll actually just install our Next.js functionality and get ourselves set up. We'll first create a new project directory, install that react to next on functionality, and then create the pages directory. So let's head on over to terminal right now. Make sure you have this up and running. This is again for you Windows users, gonna be Command prompt or PowerShell. You'll probably want to run that as an administrator. And for those of you who are using Macs or Linux, if you are running into difficulties with your commands, just try running sudo in front of them. Okay, so for starters, we need to make a project directory. I'm gonna show you in Finder where I'll put mine. There's gonna be under desktop Zenva, Next.js under course and I'm gonna pass it right here. It'll just be called something like practice because we'll be using this just over the next few sections to learn about Next.js. So I'm gonna first navigate to that location here. Zenva ... Then I want to go to next, then I want to go to courses or course. Okay, ls should confirm that there's nothing in here. So let's just clear that off. Okay. So the first thing we want to do is make a directory. I'm gonna call mine again Practice and I'm going to cd to that Practice and then I'm going to initialize npm. So I'm gonna do npm in it with the white tag and that wi ... https://www.youtube.com/watch?v=0JOBc9WsI4c
11595944 Bytes