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

Examples: Updated the example of headers to utilize the App Router #67920

Merged
merged 5 commits into from
Jul 19, 2024

Conversation

Sam-Phillemon9493
Copy link
Contributor

@Sam-Phillemon9493 Sam-Phillemon9493 commented Jul 18, 2024

This PR updates the headers example to use the App Router. Here are the changes that have been made:

  • Renamed the "pages" folder to the "app" folder.
  • Updated the routing for /, /about, and /news/[...slug] files to align with the App Router.
  • Added the layout.tsx file as part of the App Router.
  • Updated the package.json file.
  • Updated the Readme file.

cc @samcx

@ijjk ijjk added the examples Issue was opened via the examples template. label Jul 18, 2024
@ijjk
Copy link
Member

ijjk commented Jul 18, 2024

Allow CI Workflow Run

  • approve CI run for commit: 743fb04

Note: this should only be enabled once the PR is ready to go and can only be enabled by a maintainer

@Sam-Phillemon9493 Sam-Phillemon9493 marked this pull request as ready for review July 18, 2024 17:05
@samcx
Copy link
Member

samcx commented Jul 19, 2024

@Sam-Phillemon9493 I'm not seeing the updates made to the package.json?

@Sam-Phillemon9493
Copy link
Contributor Author

@Sam-Phillemon9493 I'm not seeing the updates made to the package.json?

@samcx Apologies! package.json was already up to date. I have removed that point from the comments above.

@samcx
Copy link
Member

samcx commented Jul 19, 2024

{
  "private": true,
  "scripts": {
    "dev": "next dev",
    "build": "next build",
    "start": "next start"
  },
  "dependencies": {
    "next": "latest",
    "react": "^18.2.0",
    "react-dom": "^18.2.0"
  },
  "devDependencies": {
    "@types/node": "^18.11.5",
    "@types/react": "^18.0.23",
    "@types/react-dom": "^18.0.7",
    "typescript": "^4.8.4"
  }
}

@Sam-Phillemon9493 These are not the latest (e.g., react should be on 18.3.1, etc.)

@Sam-Phillemon9493
Copy link
Contributor Author

{
  "private": true,
  "scripts": {
    "dev": "next dev",
    "build": "next build",
    "start": "next start"
  },
  "dependencies": {
    "next": "latest",
    "react": "^18.2.0",
    "react-dom": "^18.2.0"
  },
  "devDependencies": {
    "@types/node": "^18.11.5",
    "@types/react": "^18.0.23",
    "@types/react-dom": "^18.0.7",
    "typescript": "^4.8.4"
  }
}

@Sam-Phillemon9493 These are not the latest (e.g., react should be on 18.3.1, etc.)

@samcx I've updated the react and react-dom to version 18.3.1 .

@samcx
Copy link
Member

samcx commented Jul 19, 2024

@Sam-Phillemon9493 Don't forget the devDependencies as well next time!

@samcx samcx self-requested a review July 19, 2024 12:17
@samcx samcx enabled auto-merge (squash) July 19, 2024 12:17
@samcx samcx merged commit 064a524 into vercel:canary Jul 19, 2024
35 checks passed
@github-actions github-actions bot added the locked label Aug 3, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
examples Issue was opened via the examples template. locked
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants