Are everyone in this video?
Let's open the button project and let's set up the database for this project.
Okay.
So in this course and in this project I will use the MongoDB.
Okay.
So for that reason I still don't know how to set up.
Okay.
Let's look at the documentation and see that inside this let's go into the Mongo right here.
Firstly we need to install the mongoose database.
This is the core library of MongoDB library okay.
And with this thing this is the library to somehow connect with the messages okay.
It will the layer between the Next.js and MongoDB.
So which is on that Let me copy this thing.
Open a terminal.
And install that.
And let's see how we can set up.
Okay.
In order to set up the MongoDB inside the app module, we will import the mongoose module and use this
line right here.
Okay.
So my advice is never try to remember this thing okay.
Instead of let's understand this, understand the fundamental and just copy and paste okay.
That's the my advice at developers never write this by hand and never try to memorize all of that.
It doesn't really matter.
Where we go with this Mongo?
Open the app module.
Okay, but this over here.
And inside the import statement we will copy this array.
Okay.
And replace over here.
And inside of you right here we need to create a mobile device database.
Okay I'm sure you already.
Understand the basics.
So I will not deep dive about us.
Inside here.
Inside the project.
I will click on view on project also.
And I will create a new project okay.
I project and I will name for social.
Okay.
I click on next.
I just create a project.
Let's click on create a cluster.
And for now let's choose the AWS providers.
And in the region.
You can show.
In my case I will choose single box and click on Create Deployment.
Uh Right here is sideways, so.
Uh, I got one.
I just want to use the free, free version.
So I will go back and show the free version.
Okay.
So you choose the free version.
Uh, right here, I will change the name a little bit.
Will be the.
Pro.
So.
I click on Create Deployment again.
It will log the project.
And in this guy we should create the database.
Okay let's click on Create Database user.
After that right here we will click into the allow access from anywhere.
Okay, let me show you right here.
Allow search from anywhere.
We call it later.
If your router or your Wi-Fi power up.
It will change the IP address.
Okay.
So for that reason, if you are a current user.
If you are the old IP address.
And this will not work if the Wi-Fi turn off and turn on again.
So it doesn't matter.
We just click on the allow access from anywhere.
Click on that and it will pass away.
And let's go and show the connection.
Okay.
So here let me click into the rivers and do Node.js.
And let's copy this line this line right here.
And put this over here and save this application and run the holidays are here.
Now let me show you.
In order to create the documentation, we will define some schemas.
Okay.
Right here inside this is the authentication.
The reason?
Because I forgot to change the password.
Make sure you change the password over here.
Let's save us.
Okay.
Right now we are already connected to the database and start up the application successfully.
Right?
So.
I think that will be enough for this video.
I will see you in the next.