How to deny some user from navigating into a certain subtree.
Unanswered
hazamashoken posted this in #help-forum
What are some available options? Assume that the group is store in the session using Next-Auth.
group can be check with
only admin should be able to access pages in
this route guard should be implement on server side.
Answer: use put route guard in the subtree layout.tsx
group can be check with
session.user.group !== "admin"
only admin should be able to access pages in
app/admin/...
this route guard should be implement on server side.
Answer: use put route guard in the subtree layout.tsx