Skip to main content

Key Features

NodeArch brings a fresh, modular, and scalable approach to backend development in Node.js. It blends the best of TypeScript, Express, and enterprise software principles into a cohesive framework — perfect for building robust applications.

Here are the key features that set NodeArch apart:


Modular Architecture

Structure your application with clean boundaries and domain separation.

  • Organize features into self-contained modules
  • Promote scalability and clarity with a layered architecture
  • Built-in support for separation of concerns

Built-In Dependency Injection

NodeArch includes a lightweight, powerful DI container.

  • Use decorators to register and inject services
  • Support for singleton, request scoped, and transient lifetimes
  • Greatly improves testability and code reuse

Decorator-Based API (Express-Powered)

NodeArch uses TypeScript decorators to streamline development and eliminate boilerplate. Here’s a real example using Express:

@Controller()
@Tags(['User Management'])
@Use(UserMiddleware)
@HttpPath('users')
export class UserController {

constructor(private readonly userService: UserService) { }

@HttpGet('/')
async getUsers(@HttpQuery() user?: Partial<IUser>) {
return this.userService.getUsers(user);
}

@HttpGet('/:id')
async getUser(@HttpParam('id') id: string) {
return this.userService.getUser(id);
}

@HttpPost('/')
@Use(ValidationMiddleware, createUserValidation)
async createUser(@HttpBody() user: Omit<IUser, 'id'>) {
return this.userService.createUser(user);
}
}
  • Express is supported through @nodearch/express
  • Declarative routing, validation, and middleware support built-in

Powerful CLI Tooling

Speed up your development workflow using the NodeArch CLI.

  • Create new apps, components, and extensions quickly

  • Built-in commands for starting, testing, and building your app

  • Example:

    nodearch new
    nodearch start
    nodearch test
    nodearch build

Testing-Ready with Mocha

NodeArch uses Mocha as its testing foundation, and supports:

  • Service and controller unit tests via dependency injection
  • Setup/teardown patterns for module lifecycle
  • Lightweight and customizable test structure

Application Lifecycle Hooks

Need to run code on application start or shutdown? NodeArch provides a clean lifecycle hook system:

  • onStart and onStop decorators
  • Ideal for logging setup, DB connections, scheduled jobs, etc.

Express-Centric Integration

NodeArch doesn’t replace your stack — it enhances it.

  • Seamless integration with Express (via @nodearch/express)
  • Use any Express-compatible middleware
  • Support for OpenAPI decorators, validation (e.g. Joi), and custom middlewares

TypeScript Native + Build-Ready

  • Built entirely with and for TypeScript
  • First-class types and autocompletion everywhere
  • Compile-ready for production via CLI (nodearch build)

Developer Experience First

  • Simple, expressive decorators
  • Clean error messages and debug helpers
  • Logical conventions, minimal boilerplate

NodeArch isn’t just a framework — it’s your architectural foundation for building reliable, maintainable, and modern Node.js apps.