Hey there! I am building an application in NestJS and it sets the cookies from my frontend. The function that does it is this one:
res.cookie(key, value, {
httpOnly: true,
maxAge: maxAge * 1000,
path: ‘/’,
domain: mycustomdomain.com,
secure: true,
sameSite: ‘none’,
});
the problem is:
when i call the api, it sets the cookies correctly, but not its domain. Instead of my custom domain, it is being set to the backend domain (backenddomain.onrender.com) and the cookies disappears, because the difference of the domains. Is that a platform problem? I did search everywhere and i found nothing about my code, but i dont know if it is possible to fix it if it is a platform problem.