Home
NestJS
NestJS - Getting Started Guide
September 05, 2023
1 min

Table Of Contents

01
Introduction to NestJS
02
Installing
03
What’s Inside

Introduction to NestJS

NestJS is a progressive Node.js framework built with TypeScript, inspired by Angular’s architecture.

It sits on top of: Express.js

Why use NestJS?

NestJS helps you write enterprise-level backend code, not just quick scripts.

  • ✅ Clean architecture (Controller → Service → Module).
  • ✅ Built-in Dependency Injection (DI).
  • ✅ Scalable for large applications.
  • ✅ Strong TypeScript support.
  • ✅ Easy to test.

Installing

Install globally

npm install -g @nestjs/cli

Verify installation

nest --version

Create a new project:

nest new my-nest-app

Then run it:

cd my-nest-app
npm run start:dev

Open your browser:

http://localhost:3000

What’s Inside

After creating the project, you’ll see this structure:

src/
├── main.ts
├── app.module.ts
├── app.controller.ts
└── app.service.ts

Let’s break it down 👇

  • main.ts (Application Entry Point): this is where your app starts.
  • app.module.ts (Root Module): modules are the building blocks of NestJS.
  • app.controller.ts (Handles Requests) Handle HTTP requests, return responses
  • app.service.ts (Business Logic) Contain business logic, are reusable across the app

Tags

#NestJS

Share

Related Posts

NextJS
NestJS - Hexagonal Architecture
September 05, 2023
1 min
© 2026, All Rights Reserved.
Powered By

Social Media

githublinkedinyoutube