Next.js Discord

Discord Forum

Cookies and Session in middleware.ts

Unanswered
Schneider’s Smooth-fronted Caima… posted this in #help-forum
Open in Discord
Original message was deleted.

2 Replies

Singapura
I believe you can check the request path and do the session thing for required paths.
Original message was deleted
Singapura
Yes, this is the way. Nextjs docs say the same, so I guess it should be safe.