Skip to content

packages

SimonPlanje edited this page Jun 4, 2020 · 1 revision

npm packages I am going to need for my feature

"express": "^4.17.1"

Ofcourse I am going to use express, to be able to create local a server so I can interact with my database and create routes.

"mongodb": "^3.5.7"

I am going to use mongodb to make a realtime NOSQL server to insert my data into, and so I can save the input of the users in a database so it will not get lost after a restart of my own local server.

"ejs": "^3.1.3"

I need to be able to insert my data from the database into my static html page. This is where templating comes in handy. See the more in depth reason why I chose EJS here

"dotenv": "^8.2.0"

Since I am going to interact with a real mongodb database and upload my process to Github, it is important to have a secure file where I can put all my secret data into that will not be submitted to Github so no one can enter my and make adjustments to my database. Dotenv makes it possible to make an external file where data can be put in and is very easy to get back these values in the server without showing the real value that is attached to it. So it kinda works like a variable.

"body-parser": "^1.19.0",

Body parsing middleware. Parses the incoming request bodies in a middleware before the handlers do. You can get the value of the request by typing req.body. I am going to use this a lot because there will be a lot of requesting for data in this feature. I want to load in all the users on the liking page for example.

req body

"express-session": "^1.17.1",

At the end a session is going to be very important to insert the input from the user to the right id in the database. With a session the experience can be personalized for every single user because every user has another id in the database, this will also be used a lot later in the project when we are grouping up. All of the features have to have nice personalized layouts, what makes sessions a really cool npm package to use for this project.

Clone this wiki locally