Open MoharTry opened 1 year ago
Did you use app.use(cors()) in index.js? In server folder.
Did you use app.use(cors()) in index.js? In server folder.
@MoharTry
Did you use app.use(cors()) in index.js? In server folder.
We have to add it in this way only right ? Please correct me if I am wrong
Did you use app.use(cors()) in index.js? In server folder.
We have to add it in this way only right ? Please correct me if I am wrong
Yes we have to write like this.
@MoharTry try checking this out. stack-overflow
I tried every single response on this webpage but none of them helped Also what should be the Origin address of the webpage ( for origin access )? Should it be "localhost:3000" or "localhost:3000/api/v1/post"? I have added my code on my repo, can you please give a look and tell if I am doing anything wrong ? https://github.com/MoharTry/Imaginary.ai Thank you @harshit0571
the origin access should be you frontend url
.
I am getting CORS error. 'Access-Control-Allow-Origin' header is present on the requested resource. I also tried switching browsers but it doesn't help. Please let me know if anyone has figured it out