Sign in

Koa CORS cross domain

Prof edited in Tue, 06 Dec 2022

Problem description

The front-end Vue has a port of 8000, and the back-end koa uses koa CORS to cross domains. Due to the need to write cookies, it cannot return *, but it needs to return '0' http://localhost :8000'。 Now it is deployed in the production environment, and the request interface is forwarded to port 8080 through nginx. How should the origin of KOA CORS be configured?

Related codes



1 Replies
commented on Tue, 06 Dec 2022

Write down the domain name you actually use in your production environment