What convention keeps a growing Node.js codebase navigable — both at the file-naming level and the folder level?

Node.js · verified Jul 5, 2026

Fix: Two complementary, real conventions: (1) role-suffix file naming (<domain>.<kind>.js, e.g. user.controller.js) — this is exactly NestJS's official convention (cats.controller.ts, scaffolded by `nest g controller`), not a made-up pattern. (2) Organize folders by business domain/feature, not by technical layer — both classic Node.js best practices ("structure by business components/bounded contexts", each owning its own entry-point/domain/data-access folders) and the modern Feature-Sliced Design methodology (slice by domain like user/, post/, comment/, with role-based segments ui/, api/, model/ inside each slice) converge on this.

nodejsjavascriptnaming-conventionproject-structurenestjs

References