A clean and structured TypeScript boilerplate with pre-configured functions and routes.
MongoDB ( i am using docker with mongo replica set running on port 172.18.0.2 & 172.18.0.3, so please set accordingly )
-
Clone the repository:
git clone https://github.com/x3sammy/node-ts-clean-boilerplate.git
-
Navigate to the project directory:
cd typescript-clean-boilerplate -
Install dependencies:
npm install
-
Run TypeScript with server autoreload:
npm run dev
-
Build the project:
npm run build
The compiled files will be located in the
./builddirectory. -
Build and run the project:
npm run build_run
This command will build the project and start the server simultaneously.
Feel free to customize this boilerplate to suit your needs. Happy coding!