Skip to content

Backend app template with node, express, prisma compiled with ts

Notifications You must be signed in to change notification settings

mayel15/node-express-template

Repository files navigation

🩻 Node-Express Template

forthebadge

👨🏾‍💻 Pape THIAM @mayel15

🧰 Stack

nodejs express jest prisma typescript postgresql docker

➕ More

  • Supertest
  • Swagger

📄 Description of the projet

This is an opinionated boilerplate (template or skeleton, whatever you want) for Express and TypeScript. It uses Prisma as an ORM to easily switch databases with minimal code changes. This repository serves as a template to simplify the creation of new repositories from it.

⨠ Architecture

alt text

🗂️ src folder

├── controllers
├── enums
├── middlewares
├── models
├── repositories
├── routes
├── services
└── utils

🤖 Run and commands

  • ⎒ Clone the project or create a repo git from this template
git clone https://github.com/mayel15/node-express-template
  • 👽 Create an environment files at the root of the project and name them .env.dev for dev environment and .env.prod for prod environment. And after that, in those files add the environment variables you need by inspiring you in the environment template file named .env

  • 🚀 Run the server app with Docker

cd node-express-template
docker-compose up -d
  • 🕙 Wait a moment

  • ⚙️ The server will normally run at http://localhost:3000/ and the route /docs is for swagger

  • 🎞️ Overview of the runninng server

    • With Docker Desktop

      alt text

    • With the browser

      alt text

  • 🧪 Run test

npm run test

About

Backend app template with node, express, prisma compiled with ts

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published