Skip to content

Geeky-Vision/nodejs_expressjs_template

 
 

Repository files navigation

  node-current  APM  node-current


Node Js + Express Js Backend Template

The API is powered by Express.js. This Template can be used to setup a new nodejs backend project. The database is used is MongoDB Atlas.

The template contains a scalable code structure for a NodeJs based backend enabling easy to use and maintain project structure.


                 

Table of Contents
  1. Getting Started
  2. Contact

Built With

Below is the list of all the major frameworks and libraries used in the project.

(back to top)

Getting Started

To get a local copy of the API Server up and running follow these simple steps

  • Clone the repository
git clone https://github.com/himakhaitan/nodejs_expressjs_template.git
  • Install the dependencies
npm install
npm run start
  • For Development Mode
npm run dev

This will constantly look for changes in your code and restart the server automatically. Rescued Huhh!

(back to top)

Prerequisites

The prerequisites for the API server to run are the following:

  • Node.js (v16.16.0 or higher)
  • MongoDB (Locally or Cloud)
  • and you are good to go!

(back to top)

Installation

Following are the steps to configure the API Server and make it up and running.

  • Configure the Environment Variables
    • Create a file called .env in the root directory of the project
    • Add the following lines to the file
    DATABASE_URL=MONGODB_URL
    TOKEN_SECRET=PORT_TO_RUN_YOUR_SERVER
    • Replace DATABASE_URL with a MongoDB Url (Locally Hosted or Cloud Based)
    • Replace PORT with a port number of your choice.
    • Note: You can also use the sample.env file to get a template of the file

(back to top)

Contact

Feel free to reach me out on any of the above mediums (LinkedIn, Mail and Twitter for fast responses). See you in my inbox / DMs 📩 😃

          

(back to top)

Hapilly turning Coffee into Code ☕️ 💻

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%