- NodeJs: 8+
Run npm i
to install project dependencies
Run npm run dev
for a dev server.
Good
const hello = "world";
Bad
const hello = 'world';
Good
console.log("world");
Bad
console.log("world")
We use spaces. 4 spaces to be more specific.
Good
export class HelloWorld {
@Input()
public value: string;
}
Bad
export class HelloWorld {
@Input() public value: string;
}
Max line length is 140 caracters.
Good
export class HelloWorld {
constructor(private serviceA: ServiceA,
private serviceB: ServiceB,
private serviceC: ServiceC,
private serviceD: ServiceD) {}
}
Bad
export class HelloWorld {
constructor(private serviceA: ServiceA, private serviceB: ServiceB, private serviceC: ServiceC, private serviceD: ServiceD) {}
}
src
guards
interceptors
modules
pipes
utils
This section contains all the global guards of the NestJs server.
This section contains all the global interceptors of the NestJs server.
This section contains all the modules of the NestJs server.
Each module can have a controller, a service and a model. All modules must define a NestJs module.
This section contains all the global pipes of the NestJs server.
This section contains all the utils of the NestJs server.