//main.ts
app.enableCors({
origin: '*',
methods: 'GET,HEAD,PUT,PATCH,POST,DELETE',
preflightContinue: true,
optionsSuccessStatus: 204,
credentials: true,
allowedHeaders: [
'Origin',
'X-Requested-With',
'Content-Type',
'Accept',
'Content-Type',
'Authorization',
],
});