You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm aware that this is, technically speaking, a duplicate (#3728), but I think it's ok because the duplicates are a little bit old now.
The organization system required by Next.js feels lousy for many people, myself included. For reference, this is what I mean:
pages
page1.tsx
page2.tsx
...
page[x].tsx
components
page1
[components]
page2
[components]
...
page[x]
[components]
On the other hand, something like this would feel much nicer. Let's pretend that any files in the "lib" folder do not get rendered as pages:
pages
page1
index.tsx
lib
[components]
page2
index.tsx
lib
[components]
...
page[x]
index.tsx
lib
[components]
Any updates on getting this implemented for 2021? I hate to be "that guy" who complains on github forums, but this seems like something that would be very easy to program into Next.js All the programmer would have to do is dynamically restructure the folder system of the 2nd example to be like the 1st when the code is being built.
Other than this one thing, I'm enjoying Next.js quite a bit, and cheers to the devs.
Describe the solution you'd like
(explained in the above section)
Describe alternatives you've considered
(explained in the above section)
The text was updated successfully, but these errors were encountered:
Johnrobmiller
changed the title
Having a separate "components" and "pages" folder feels bad man. /:
Having a separate "components" and "pages" folder feels bad, man. /:
Apr 13, 2021
In a "component thinking way" what you should consider when using React, there is no need to separate components by pages. Do you have a specific use case why you do that? What about general components like buttons in your example? For me it makes totally sense to use a page as the rendered outcome composition where all your specific components are used.
Describe the feature you'd like to request
I'm aware that this is, technically speaking, a duplicate (#3728), but I think it's ok because the duplicates are a little bit old now.
The organization system required by Next.js feels lousy for many people, myself included. For reference, this is what I mean:
On the other hand, something like this would feel much nicer. Let's pretend that any files in the "lib" folder do not get rendered as pages:
Any updates on getting this implemented for 2021? I hate to be "that guy" who complains on github forums, but this seems like something that would be very easy to program into Next.js All the programmer would have to do is dynamically restructure the folder system of the 2nd example to be like the 1st when the code is being built.
Other than this one thing, I'm enjoying Next.js quite a bit, and cheers to the devs.
Describe the solution you'd like
(explained in the above section)
Describe alternatives you've considered
(explained in the above section)
The text was updated successfully, but these errors were encountered: