SupabaseS
Supabaseβ€’4y ago
b3n123

Multiple middleware auth

So my web app requires authentication to access all pages. There are also some pages which only admins can access (their role is defined in raw_app_meta_data).

Middleware seems the best way to achieve this but I'm unsure how to achieve this or if it's even possible since I think it would need 2 middleware files.

Would middleware be the best way forward or are there better ways?

Any help is appreciated πŸ™‚
Was this page helpful?