Code architecture best practices for large codebases in the context of t3 stack

What do you think of this code architecture in the scenario where you are working in large codebase with many apps
.
├── apps/
│ ├── nextjs-app
│ ├── mobile-app
│ ├── docs site
│ └── ...
└── libs/
├── shared/
│ ├── data-layer/
│ │ └── libs...
│ ├── feature-layer /
│ │ └── libs...
│ └── ui-layer/
│ └── libs...
├── nextjs-app/
│ ├── data-layer/
│ │ └── libs...
│ ├── feature-layer/
│ │ └── libs...
│ └── ui-layer/
│ └── libs...
└── mobile-app/
├── data-layer/
│ └── libs...
├── feature-layer/
│ └── libs...
└── ui-layer/
└── libs...
.
├── apps/
│ ├── nextjs-app
│ ├── mobile-app
│ ├── docs site
│ └── ...
└── libs/
├── shared/
│ ├── data-layer/
│ │ └── libs...
│ ├── feature-layer /
│ │ └── libs...
│ └── ui-layer/
│ └── libs...
├── nextjs-app/
│ ├── data-layer/
│ │ └── libs...
│ ├── feature-layer/
│ │ └── libs...
│ └── ui-layer/
│ └── libs...
└── mobile-app/
├── data-layer/
│ └── libs...
├── feature-layer/
│ └── libs...
└── ui-layer/
└── libs...
8 Replies
barry
barry2y ago
this already looks like a nightmare of mvc infiltrating the app
endalk200
endalk2002y ago
Don't look at it from the context of small apps. Imagine you have huge codebase with multiple engineers working on it.
cje
cje2y ago
whats the point of having two different nextjs-app folders
endalk200
endalk2002y ago
It is just an example. You can imagine whatever app you want. internal dashboard or ...
cje
cje2y ago
├── apps/
│ └── nextjs-app
└── libs/
└── nextjs-app/
└── ui-layer/
└── libs...
├── apps/
│ └── nextjs-app
└── libs/
└── nextjs-app/
└── ui-layer/
└── libs...
you do you but this seems silly to me
endalk200
endalk2002y ago
I'm asking for your thoughts. I think code organization and architecture is something we all want to get right but you will produce crappy once first.
endalk200
endalk2002y ago
Nx
Grouping Libraries
Next generation build system with first class monorepo support and powerful integrations.
endalk200
endalk2002y ago
Nx
Library Types
Next generation build system with first class monorepo support and powerful integrations.
Want results from more Discord servers?
Add your server