Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: Next 13 Root Layout #2300

Merged
merged 16 commits into from
May 7, 2024

Conversation

eduardoformiga
Copy link
Member

@eduardoformiga eduardoformiga commented May 3, 2024

Depends on

What's the purpose of this pull request?

This PR aims to create the root layout.tsx and bring the components from the src folder to the app folder.

Most of the changes from this PR are related to the path change to the app folder. But there are also new 'use clients' added to some components.

The sections should be implemented/moved in other PR's related to another JIRA task.

How to test it?

Make sure that the older pages are working as expected and also the http://localhost:3000/fs-next-update is rendering (blank) without errors.

Starter PR

TBD

References

https://nextjs.org/docs/app/api-reference/file-conventions/layout

Copy link

vercel bot commented May 3, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
faststore-site ⬜️ Ignored (Inspect) Visit Preview May 7, 2024 6:53pm

Copy link

codesandbox-ci bot commented May 3, 2024

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

@eduardoformiga eduardoformiga marked this pull request as ready for review May 3, 2024 21:22
@eduardoformiga eduardoformiga requested a review from a team as a code owner May 3, 2024 21:22
@eduardoformiga eduardoformiga requested review from renatamottam and lariciamota and removed request for a team May 3, 2024 21:22
@eduardoformiga eduardoformiga added the depends on Depends on another PR label May 3, 2024
Copy link
Contributor

@lariciamota lariciamota left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: I thought we were going to put the app directory inside /src, why not put it inside? Will we change it after fully migrating?

@eduardoformiga
Copy link
Member Author

question: I thought we were going to put the app directory inside /src, why not put it inside? Will we change it after fully migrating?

We can put as this doc explains.
But at this time, I think it would be safer to keep far from the older code just to give us a better perception of the changes, as we will probably need to keep some duplicated files to mantain retro compatibility with older APIs.

Base automatically changed from feat/next-13-initial-setup to main May 6, 2024 23:12
@eduardoformiga eduardoformiga merged commit 1d06d4e into main May 7, 2024
7 checks passed
@eduardoformiga eduardoformiga deleted the feat/next-13-global-section-root-layout-SFS-881 branch May 7, 2024 18:56
eduardoformiga added a commit that referenced this pull request May 7, 2024
Depends on
- #2298 
- #2300

## What's the purpose of this pull request?

This PR aims to migrate to the new way to fetch data using Next 13.

## How it works?

instead of `getServerStaticProps`, now we fetch the data directly from
the root `layout.tsx`.

## How to test it?

locally, add a console log after the fetch function.


## References

https://nextjs.org/docs/app/building-your-application/data-fetching
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
depends on Depends on another PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants