I'm just starting out with developing loopback, and I just want to know how to set cookies in a browser using loopback. You can send the cookie explicitly to nodejs by setting it in the headers and then accessing it later.
response.writeHead(200, { 'Set-Cookie': 'mycookie=test', 'Content-Type': 'text/plain' });
So how to do this with the return loop.
Thank.
He had a simple solution. Using core node.js to solve it:
since we have a context in loopback, therefore:
context.res.setHeader("Set-Cookie",'cookie='+ cookieId);
This would also do a loopback trick.
Loopback Express, cookie-session cookie Express, .