/
watchadoing
/
mega-session
Обзор
Документация
Войти
/
watchadoing
/
mega-session
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
master
backend/src/main.ts
18 строк
583 B
Andrey Isaev
first_commit
29 окт 2025, 17:45
29 окт 2025, 17:45
6cc50d7
Код
Авторство
О чём код?
import { NestFactory } from '@nestjs/core'; import { AppModule } from './app.module'; import { ValidationPipe } from '@nestjs/common'; import { WINSTON_MODULE_NEST_PROVIDER } from 'nest-winston'; import 'dotenv/config'; async function bootstrap() { const app = await NestFactory.create(AppModule); app.setGlobalPrefix('api/afisha'); app.useGlobalPipes(new ValidationPipe({ transform: true })); app.useLogger(app.get(WINSTON_MODULE_NEST_PROVIDER)); app.enableCors({ origin: 'http://localhost:5173', credentials: true, }); await app.listen(3000); } bootstrap();