Next.js Discord

Discord Forum

Seeking Advice on Migrating File Structure in Next.js Project

Unanswered
Sloth bear posted this in #help-forum
Open in Discord
Sloth bearOP
I'm currently contemplating a significant change in the file structure of my Next.js project and would appreciate your insights.

Currently, my project is structured with the conventional src/pages directory, housing the key files like index.tsx, _document.tsx, and _app.tsx. This setup has served well, but I'm considering a shift towards a more modular approach.

I'm thinking of migrating to a structure where I use app/page.tsx and layout.tsx instead. The goal is to enhance organization and scalability as the project grows.

Before I proceed, I would love to hear from the community:

-Have any of you undertaken a similar migration in your Next.js projects? If so, what was your experience like?
-Are there any significant benefits or drawbacks I should be aware of with this new structure?
-Would you recommend this transition for a project focused on [mention any specific aspects like scalability, maintainability, team collaboration, etc.]?

0 Replies