enabling cors
This commit is contained in:
parent
3f258bcd33
commit
f72047b18e
1 changed files with 1 additions and 0 deletions
|
|
@ -4,6 +4,7 @@ import { NestExpressApplication } from '@nestjs/platform-express';
|
||||||
|
|
||||||
async function bootstrap(): Promise<void> {
|
async function bootstrap(): Promise<void> {
|
||||||
const app = await NestFactory.create<NestExpressApplication>(AppModule);
|
const app = await NestFactory.create<NestExpressApplication>(AppModule);
|
||||||
|
app.enableCors();
|
||||||
app.setGlobalPrefix(process.env.PREFIX ?? 'common-cents');
|
app.setGlobalPrefix(process.env.PREFIX ?? 'common-cents');
|
||||||
await app.listen(process.env.PORT ?? 3000);
|
await app.listen(process.env.PORT ?? 3000);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue