Any reason why CORS would fail with
Access to fetch at 'http://localhost:3000/v1/auth/signin' from origin 'http://localhost:4200' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: The value of the 'Access-Control-Allow-Origin' header in the response must not be the wildcard '*' when the request's credentials mode is 'include'.
cors:
app.enableCors({
origin: "http://localhost:4200",
allowedHeaders: ["content-type", ...supertokens.getAllCORSHeaders()],
credentials: true,
});
backend config:
{
config: {
appInfo: {
appName: 'app',
apiDomain: 'http://localhost:3000',
websiteDomain: 'http://localhost:4200',
apiBasePath: '/v1/auth',
websiteBasePath: '/auth'
},
connectionURI: 'http://auth:3567',
apiKey: 'supersecret'
}
}
frontend config:
apiBasePath: "/v1/auth"
apiDomain: "http://localhost:3000"
appName: "app"
websiteBasePath: "/auth"
websiteDomain: "http://localhost:4200"
EDIT: using nestjs