vasyldubno
vasyldubno
RRailway
Created by vasyldubno on 6/16/2023 in #✋|help
Couldn't set cookie, nestjs
Project ID: eb9aa9c1-aabe-4f51-9a40-40193647b820 i deploy frontend to vercel, backend to railway. my route that set cookie 'res .cookie('jwt-token', refreshToken, { httpOnly: true, secure: true, sameSite: 'none', maxAge: 30 * 24 * 60 * 60 * 1000, }) .json({ accessToken, id: user.id })'. in main.ts i added cors 'app.use(cors({ origin: process.env.CLIENT_URL, credentials: true }));'. my cookie don't setting
27 replies
RRailway
Created by vasyldubno on 6/16/2023 in #✋|help
Couldn't set cookie, nestjs
i deploy frontend to vercel, backend to railway. my route that set cookie 'res .cookie('jwt-token', refreshToken, { httpOnly: true, secure: true, sameSite: 'none', maxAge: 30 * 24 * 60 * 60 * 1000, }) .json({ accessToken, id: user.id })'. in main.ts i added cors 'app.use(cors({ origin: process.env.CLIENT_URL, credentials: true }));'. my cookie don't setting
4 replies