Courses / Node.js
32. Sessions with server-side storage
Implement session creation, storage, and retrieval using express-session or similar with a persistent store.
JavaScript
Sessions with server-side storage
A way to remember who a user is across multiple HTTP requests by storing session data on the server and a small session id in the user's cookie.
"I want users to stay logged in and keep a shopping cart without trusting the browser to store everything."
Server-side sessions store user-specific data on the server and give the browser a short opaque session id cookie; the server looks up data for each incoming request using that id.
"I want users to stay logged in and keep a shopping cart without trusting the browser to store everything."
Server-side sessions store user-specific data on the server and give the browser a short opaque session id cookie; the server looks up data for each incoming request using that id.