CRUD Using Node.js, Express, And Sequelize

Node.js basic project structure. How to create a RESTful application using the above technologies

Vinesh
The Jabberjays

--

Let’s build a RESTful application using the following technologies

  • Node.js
  • Express
  • Sequelize
  • PostgreSQL

Create Project And Install Dependencies

Please install node on the system if you haven’t already https://nodejs.org/en/download/

Let’s first create a node.js project.

mkdir codegig
cd codegig
npm init -y

So the above 3 lines will create a directory called codegig and we switch to it, then we run the npm init -y which will create the package.json for us. We’ll be using VScode IDE for programming but you can use other IDEs which you are familiar with.

Now we move on to installing the required dependencies for our project.

npm i body-parser express pg pg-hstore sequelize cors
npm i --save-dev nodemon

So running the above command in CLI allows us to download the dependencies and adds it to the package.json. We use express since it is the best framework on node.js which allows us to…

--

--

Vinesh
The Jabberjays

Coder 👨‍💻, Gamer🎮 and a dog person🐶. That says a lot about me, I guess😛.