Layout for a Route Group in NextJS
Let's talk about cases when a website is divided into several parts, for example, the main part and the admin panel. In this case, they are fundamentally different and we need a separate layout for each of the parts.
- /app/
- /(user)/
- layout.jsx
- /(admin)/
- layout.jsx
- /(user)/
Divide the site into two parts. Create a main layout for each of the parts.