13 lines
352 B
TypeScript
13 lines
352 B
TypeScript
import { NestFactory } from "@nestjs/core";
|
|
import { AppModule } from "./app.module";
|
|
|
|
const DEFAULT_PORT = 3001;
|
|
|
|
async function bootstrap() {
|
|
const app = await NestFactory.create(AppModule);
|
|
app.enableCors();
|
|
await app.listen(process.env.PORT ?? DEFAULT_PORT);
|
|
}
|
|
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
|
bootstrap();
|