Skip to content
New issue

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

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

Already on GitHub? # to your account

chore(examples): update React in reproduction templates to stable 19 #74499

Merged
merged 5 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions examples/reproduction-template-pages/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# local env files
.env*.local
# env files (can opt-in for committing if needed)
.env*

# vercel
.vercel
Expand Down
6 changes: 0 additions & 6 deletions examples/reproduction-template-pages/next.config.js

This file was deleted.

8 changes: 8 additions & 0 deletions examples/reproduction-template-pages/next.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import type { NextConfig } from "next";

const nextConfig: NextConfig = {
/* config options here */
reactStrictMode: true,
};

export default nextConfig;
10 changes: 5 additions & 5 deletions examples/reproduction-template-pages/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
},
"dependencies": {
"next": "canary",
"react": "19.0.0-beta-04b058868c-20240508",
"react-dom": "19.0.0-beta-04b058868c-20240508"
"react": "^19.0.0",
"react-dom": "^19.0.0"
},
"devDependencies": {
"@types/node": "20.4.5",
"@types/react": "18.2.18",
"typescript": "5.1.3"
"@types/node": "^22",
"@types/react": "^19",
"typescript": "^5"
}
}
21 changes: 14 additions & 7 deletions examples/reproduction-template-pages/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,20 +1,27 @@
{
"compilerOptions": {
"target": "es5",
"target": "ES2017",
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": false,
"forceConsistentCasingInFileNames": true,
"strict": true,
"noEmit": true,
"incremental": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "node",
"moduleResolution": "bundler",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve"
"jsx": "preserve",
"incremental": true,
"plugins": [
{
"name": "next"
}
],
"paths": {
"@/*": ["./*"]
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
"exclude": ["node_modules"]
}
7 changes: 4 additions & 3 deletions examples/reproduction-template/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# dependencies
/node_modules
/.pnp0
/.pnp
.pnp.*
.yarn/*
!.yarn/patches
Expand All @@ -28,9 +28,10 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# local env files
.env*.local
# env files (can opt-in for committing if needed)
.env*

# vercel
.vercel
Expand Down
9 changes: 6 additions & 3 deletions examples/reproduction-template/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
export default function RootLayout({ children }) {
export default function RootLayout({
children,
}: Readonly<{
children: React.ReactNode;
}>) {
return (
<html>
<head />
<html lang="en">
<body>{children}</body>
</html>
);
Expand Down
8 changes: 0 additions & 8 deletions examples/reproduction-template/next.config.mjs

This file was deleted.

8 changes: 8 additions & 0 deletions examples/reproduction-template/next.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import type { NextConfig } from "next";

const nextConfig: NextConfig = {
/* config options here */
reactStrictMode: true,
};

export default nextConfig;
7 changes: 3 additions & 4 deletions examples/reproduction-template/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,8 @@
"react-dom": "^19.0.0"
},
"devDependencies": {
"@types/node": "20.12.12",
"@types/react": "18.3.3",
"@types/react-dom": "18.3.0",
"typescript": "5.3.3"
"@types/node": "^22",
"@types/react": "^19",
"typescript": "^5"
}
}
14 changes: 8 additions & 6 deletions examples/reproduction-template/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,24 +1,26 @@
{
"compilerOptions": {
"target": "es5",
"target": "ES2017",
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": false,
"forceConsistentCasingInFileNames": true,
"strict": true,
"noEmit": true,
"incremental": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "node",
"moduleResolution": "bundler",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve",
"incremental": true,
"plugins": [
{
"name": "next"
}
]
],
"paths": {
"@/*": ["./*"]
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
"exclude": ["node_modules"]
Expand Down
Loading