Compare commits
3 Commits
d66279885b
...
7802808f62
| Author | SHA1 | Date |
|---|---|---|
|
|
7802808f62 | |
|
|
3f582917fd | |
|
|
c4fdfb1280 |
|
|
@ -3,15 +3,11 @@ import { AppModule } from './app.module';
|
|||
|
||||
|
||||
async function bootstrap() {
|
||||
const app = await NestFactory.create(AppModule);
|
||||
const app = await NestFactory.create(AppModule, { cors: false });
|
||||
|
||||
//настройка CORS
|
||||
|
||||
app.enableCors({
|
||||
origin: '*',
|
||||
methods: 'GET,HEAD,PUT,PATCH,POST,DELETE,OPTIONS',
|
||||
allowedHeaders: 'Content-Type, Authorization',
|
||||
});
|
||||
|
||||
await app.listen(process.env.PORT ?? 3000);
|
||||
}
|
||||
bootstrap();
|
||||
Loading…
Reference in New Issue