Template - API
WelcomePrerequisitesNodeJS
  • Welcome!
    • About me
  • Prerequisites
    • Installation and Database Setup
    • Installing Node.js on the Server
  • NodeJS
    • 🆓Getting Started with the Free Template
    • 🎗️Premium Template - REST API
      • Structure
      • Middlewares and Guards
      • Core Modules
        • Prisma with NestJS
        • Swagger with NestJS
      • Dynamic Module
        • Create or Import Module
  • Modules
    • 🎗️Websockets
    • 🎗️Mailer
    • 🎗️Upload
Powered by GitBook
On this page
  1. NodeJS
  2. Premium Template - REST API

Structure

Each module has well-defined services, controllers, and decorators to handle specific functionalities. The project follows best practices for scalability and performance optimization.

Main Components

  • app.module.ts: The main application module that bootstraps the application.

  • main.ts: Entry point for the application, responsible for initializing the Nest application.

Common

  • decorators: Custom decorators like dynamic.module.decorator.ts.

  • interfaces: Defines contracts for various components, such as apply-middleware.interface.ts.

  • middlewares: Abstract middlewares like abstract-middleware-loader.ts for reusable logic.

  • modules: Contains reusable modules such as dynamic-modules.ts and error-handling with error-handler.filter.ts.

  • services: Services that handle dynamic module loading and other common features, e.g., dynamic-modules-loader.service.ts.

Configuration

  • cache.configuration.ts and env.configuration.ts: Handles cache and environment configurations.

PreviousPremium Template - REST APINextMiddlewares and Guards

Last updated 8 months ago

🎗️