Skip to content

Commit

Permalink
chore: update next 14 -> 15
Browse files Browse the repository at this point in the history
  • Loading branch information
bysxx committed Oct 22, 2024
1 parent 174fa81 commit e36ce2c
Show file tree
Hide file tree
Showing 120 changed files with 2,281 additions and 935 deletions.
1,694 changes: 1,195 additions & 499 deletions .pnp.cjs

Large diffs are not rendered by default.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
4 changes: 2 additions & 2 deletions app/(client)/(main)/page.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
export default function MainPage() {
return (
<main className="flex min-h-screen w-full flex-col items-center p-8">
<h1 className="mb-4 text-5xl font-bold">Welcome to Next.js 14</h1>
<p className="text-lg">Next 14 + TypeScript + TailwindCSS</p>
<h1 className="mb-4 text-5xl font-bold">Welcome to Next.js 15</h1>
<p className="text-lg">Next 15 + TypeScript + TailwindCSS</p>
</main>
);
}
3 changes: 2 additions & 1 deletion app/(client)/example/dynamic/[id]/page.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
export default function ExampleDynamicPage({ params }: { params: { id: string } }) {
export default async function ExampleDynamicPage(props: { params: Promise<{ id: string }> }) {
const params = await props.params;
return (
<main className="flex min-h-screen flex-col items-center p-8">
<div className="flex flex-col gap-y-4">
Expand Down
11 changes: 6 additions & 5 deletions app/(client)/example/query-string/page.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
export default function QueryStringPage({
searchParams,
}: {
searchParams?: { [key: string]: string | string[] | undefined };
}) {
export default async function QueryStringPage(
props: {
searchParams?: Promise<{ [key: string]: string | string[] | undefined }>;
}
) {
const searchParams = await props.searchParams;
return (
<main className="flex min-h-screen flex-col items-center p-8">
{searchParams && (
Expand Down
2 changes: 1 addition & 1 deletion next-env.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
/// <reference types="next/image-types/global" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.
// see https://nextjs.org/docs/app/building-your-application/configuring/typescript for more information.
3 changes: 3 additions & 0 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ const nextConfig = {
compiler: {
removeConsole: false,
},
experimental: {
reactCompiler: true,
}
};

module.exports = nextConfig;
23 changes: 14 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,13 @@
"@tanstack/react-query": "^5.29.2",
"@tanstack/react-query-devtools": "^5.29.2",
"@tanstack/react-query-next-experimental": "^5.29.2",
"babel-plugin-react-compiler": "19.0.0-beta-8a03594-20241020",
"classnames": "^2.5.1",
"mongoose": "^8.3.1",
"next": "^14.2.5",
"next": "^15.0.0",
"postcss": "^8.4.38",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react": "19.0.0-rc-65a56d0e-20241020",
"react-dom": "19.0.0-rc-65a56d0e-20241020",
"tailwindcss": "^3.4.3",
"zustand": "^4.5.2"
},
Expand All @@ -38,22 +39,22 @@
"@testing-library/react": "^15.0.1",
"@types/jest": "^29.5.12",
"@types/node": "^20.12.7",
"@types/react": "^18.2.77",
"@types/react-dom": "^18.2.25",
"@types/react": "npm:types-react@19.0.0-rc.1",
"@types/react-dom": "npm:types-react-dom@19.0.0-rc.1",
"@typescript-eslint/eslint-plugin": "^7.6.0",
"@typescript-eslint/parser": "^7.6.0",
"eslint": "^8.57.0",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-config-airbnb-typescript": "^18.0.0",
"eslint-config-next": "^14.2.5",
"eslint-config-next": "^15.0.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jest": "^28.2.0",
"eslint-plugin-jest-dom": "^5.2.0",
"eslint-plugin-jest-formatting": "^3.1.0",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-react": "^7.34.1",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react": "^7.37.1",
"eslint-plugin-react-hooks": "^5.0.0",
"eslint-plugin-simple-import-sort": "^12.0.0",
"eslint-plugin-tailwindcss": "^3.15.1",
"eslint-plugin-testing-library": "^6.2.0",
Expand All @@ -63,5 +64,9 @@
"prettier": "^3.2.5",
"typescript": "^5.4.5"
},
"packageManager": "yarn@4.3.1"
"packageManager": "yarn@4.3.1",
"resolutions": {
"@types/react": "npm:types-react@19.0.0-rc.1",
"@types/react-dom": "npm:types-react-dom@19.0.0-rc.1"
}
}
2 changes: 1 addition & 1 deletion src/components/ui/global-nav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ function GlobalNav() {
return (
<nav className="sticky top-0 grid h-16 w-full grid-cols-2 items-center justify-center bg-[hsla(0,0%,100%,.8)] px-8 py-4 shadow-bottom backdrop-blur-sm backdrop-saturate-150">
<div className="flex justify-start text-2xl text-gray-900">
<Link href="/">Next 14</Link>
<Link href="/">Next 15</Link>
</div>

<div className="flex justify-end gap-x-2 text-gray-500">
Expand Down
Loading

0 comments on commit e36ce2c

Please sign in to comment.