Skip to content

Node.js project with TypeScript, Express.js ESLint, Prettier & more.

NotificationsYou must be signed in to change notification settings

reneSpeaks/TypeScript-API

Repository files navigation

TypeScript API

This repository was created in an effort to learn how to create REST-API's with TypeScript. Following best practices in production environments I not only set up the repository for my own personal use, but put much effort into understanding Actions Workflows, including many collaborative tools like ESLint and Prettier so development in a team is not only possible but functional.

It was quite a wonderful teaching exercise.

Technologies & Tools Used

  • Node.js: Basis of this project to leverage the benefits of server-side JavaScript.
  • TypeScript: Improved code quality and static typing.
  • Express.js: To create a robust and scalable REST-API.
  • ESLint: Static code analysis to identify and fix problematic patterns as they happen.
  • Prettier: Code formatting to ensure consistency and aesthetically pleasing code.
  • CORS: Handling Cross-Origin Resource Sharing to allow controlled access to resources from different domains.
  • Vitest: Testing library for Test Driven Development approach.
  • Workflows & Scripts: Environment specific scripts handle not only linting and formatting, but also the test environment before commiting. Additional safeguards are used using Actions.

Project Setup

Follow the steps below to set up the project on your local system:

  1. Clone the Repository: git clone [email protected]:reneSpeaks/TypeScript-API.git
  2. Install dependencies npm i
  3. Copy and fill out .env.Example to create .env.development & .env.production
  4. Start development Server: npm run dev
  5. Open URL: http://localhost:3001