Note: This repo is folk from https://github.com/sunhak-hout/express-ts-api-boilerplate which use MongoDB for database.
All you have been looking for with ExpressJS + Typescript + Relational Database with Prisma:
- Simple Clean Code Structure
- Custom Error Handlings
- Module Aliases
- Prisma Example
- Existing Sample Code
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. Feel free to play around ;)
Make sure your NodeJS and NPM on your local machine is up to date. NodeJS LTS version is recommended.
node --version # v14.16.0 or above
npm --version # v6.14.11 or aboveClone the project
git clone https://github.com/sinh117801/express-ts-api-boilerplate.gitMove into the project folder
cd express-ts-api-boilerplateConfig Environment Variables
cp .env.example .env
# set value of each variables in '.env' fileInstall dependencies, prisma migration and start
npm install
npx prisma migrate dev
npm run devSeeding the data into database
npx prisma db seed --preview-featureAll pull requests and feedbacks are welcome and appreciated ;)
- Sinh Noun - Javascript Developer - Mbanq Cloud
To all NodeJS and Typescript and other related field contributors, thank you! <3