
Anyone have use case to implement middleware to protect dashboard & login page?
I try to implement middleware on nextjs with api to check current session, but it's not gonna work.

Server side rendering is a huge pain. I highly recommend sticking with client side code if possible

You can check this repo for SSR: https://github.com/Meldiron/appwrite-ssr-next-js
But keep in mind the cookie explanation, as you won't be able to get the appwrite cookie in your middleware if that isn't solved
Recommended threads
- Oauth2-Error 400Invalid `success` param:...
My code: > await new Account(client).createOAuth2Session(OAuthProvider.Google, 'https://www.mydomain.online/home', 'https://www.mydomain.online'); I ha...
- Issue with `listDocuments` when using qu...
Hello, Appwrite team! I'm having an issue with `listDocuments` when using query modifiers: **Environment:** - Self-hosted Appwrite (`Version 1.4.13`) installe...
- Function gives unauthorized error when w...
I am on free tier. I have function that has three attributes: 1. A stand alone attribute (required) 2. A many to one relationship attribute 3. A many to man...
