1.0.4 • Published 2 years ago

@adomne/express-ts-jest-boilerplate v1.0.4

Weekly downloads
-
License
Apache-2.0
Repository
-
Last release
2 years ago

Express-Typescript-Jest-Boilerplate

Skeleton for Express.js applications written in TypeScript with testing support and CI/CD out of the box.

Purpose

The main purpose of this Skeleton is to start an Express Application with typescript, testing support and default CI/CD configuration.

Common Features

  • Integrated eslint, prettier, jest, and husky.
  • CI/CD Configuration by default.
  • Simple and Standard scaffolding.
  • Based on Typescript Syntax.
  • Integrated morgan logger.
  • Test cases Support.

Core NPM Modules

  • express
  • express-actuator
  • helmet
  • dotenv
  • cors
  • mongoose
  • morgan

Set Application

  • Install using npx @adomne/express-ts-jest-boilerplate my-own-starter-project

OR

  • Clone the Application git clone https://github.com/adomne/express-ts-jest-boilerplate.git
  • Install the dependencies npm install

Project Structure

NameDescription
.husky/Git hooks configuration
.github/Github actions configuration
.vscode/Launch options for jest (using Jest ext from orta)
api/Endpoint testing (using thunder client ext)
config/Environment files
CI/CI/CD configuration steps
dist/Compiled source files will be placed here
src/Source files
src/controllersBusiness logic for routes
src/dbDB connectors
src/middleware/Middlewares like Async Handler feature
src/modelsModel definitions
src/routersRoute definitions
src/services3rd party services
tests/Test cases will be placed here

Default System Health Status API

  • ${host}/info - Displays application information
  • ${host}/metrics - Shows metrics information for the current application.
  • ${host}/health - Shows application health information.

Notes

1. Husky Configuration files (pre-commit and pre-push)

  • Check CONFIGURATION.md inside .husky folder.

2. Check Express Best Practices to Secure Your App

Follow us on Twitter, Instagram, Linkedin, and Github.