79375818

Date: 2025-01-21 20:17:40
Score: 4
Natty:
Report link

I have the same problem and solved it by adding app.enableCorse() in main.ts file in nest

async function bootstrap() {
  const app = await NestFactory.create(AppModule);
  app.enableCors()
  await app.listen(process.env.PORT ?? 4000);
}

and i hope this work with you two , this allow the Cors to Get Requests from origin points ==> localhost

Reasons:
  • Blacklisted phrase (1): I have the same problem
  • Has code block (-0.5):
  • Me too answer (2.5): I have the same problem
  • Low reputation (1):
Posted by: Ali Elkishawi