Skip to content

Commit 94adf33

Browse files
authored
examples: Upgrade core-team-maintained examples to Next.js 16 (#11014)
### Description Updating core-maintained examples to Next.js 16. ### Testing Instructions CI, and I also hand-tested them all.
1 parent 97668fe commit 94adf33

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+3117
-6087
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/// <reference types="next" />
22
/// <reference types="next/image-types/global" />
3+
import "./.next/types/routes.d.ts";
34

45
// NOTE: This file should not be edited
56
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

examples/basic/apps/docs/package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@
44
"type": "module",
55
"private": true,
66
"scripts": {
7-
"dev": "next dev --turbopack --port 3001",
7+
"dev": "next dev --port 3001",
88
"build": "next build",
99
"start": "next start",
10-
"lint": "next lint --max-warnings 0",
11-
"check-types": "tsc --noEmit"
10+
"lint": "eslint --max-warnings 0",
11+
"check-types": "next typegen && tsc --noEmit"
1212
},
1313
"dependencies": {
1414
"@repo/ui": "workspace:*",
15-
"next": "^15.5.0",
16-
"react": "^19.1.0",
15+
"next": "^16.0.0",
16+
"react": "^19.2.0",
1717
"react-dom": "^19.1.0"
1818
},
1919
"devDependencies": {
@@ -22,7 +22,7 @@
2222
"@types/node": "^22.15.3",
2323
"@types/react": "19.1.0",
2424
"@types/react-dom": "19.1.1",
25-
"eslint": "^9.34.0",
25+
"eslint": "^9.38.0",
2626
"typescript": "5.9.2"
2727
}
2828
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
/// <reference types="next" />
22
/// <reference types="next/image-types/global" />
3+
import "./.next/types/routes.d.ts";
34

45
// NOTE: This file should not be edited
56
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.

examples/basic/apps/web/package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@
44
"type": "module",
55
"private": true,
66
"scripts": {
7-
"dev": "next dev --turbopack --port 3000",
7+
"dev": "next dev --port 3000",
88
"build": "next build",
99
"start": "next start",
10-
"lint": "next lint --max-warnings 0",
11-
"check-types": "tsc --noEmit"
10+
"lint": "eslint --max-warnings 0",
11+
"check-types": "next typegen && tsc --noEmit"
1212
},
1313
"dependencies": {
1414
"@repo/ui": "workspace:*",
15-
"next": "^15.5.0",
16-
"react": "^19.1.0",
15+
"next": "^16.0.0",
16+
"react": "^19.2.0",
1717
"react-dom": "^19.1.0"
1818
},
1919
"devDependencies": {
@@ -22,7 +22,7 @@
2222
"@types/node": "^22.15.3",
2323
"@types/react": "19.1.0",
2424
"@types/react-dom": "19.1.1",
25-
"eslint": "^9.34.0",
25+
"eslint": "^9.38.0",
2626
"typescript": "5.9.2"
2727
}
2828
}

examples/basic/packages/eslint-config/next.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import js from "@eslint/js";
2+
import { globalIgnores } from "eslint/config";
23
import eslintConfigPrettier from "eslint-config-prettier";
34
import tseslint from "typescript-eslint";
45
import pluginReactHooks from "eslint-plugin-react-hooks";
@@ -17,6 +18,13 @@ export const nextJsConfig = [
1718
js.configs.recommended,
1819
eslintConfigPrettier,
1920
...tseslint.configs.recommended,
21+
globalIgnores([
22+
// Default ignores of eslint-config-next:
23+
".next/**",
24+
"out/**",
25+
"build/**",
26+
"next-env.d.ts",
27+
]),
2028
{
2129
...pluginReact.configs.flat.recommended,
2230
languageOptions: {

examples/basic/packages/eslint-config/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"devDependencies": {
1212
"@eslint/js": "^9.34.0",
1313
"@next/eslint-plugin-next": "^15.5.0",
14-
"eslint": "^9.34.0",
14+
"eslint": "^9.38.0",
1515
"eslint-config-prettier": "^10.1.1",
1616
"eslint-plugin-only-warn": "^1.1.0",
1717
"eslint-plugin-react": "^7.37.5",

examples/basic/packages/ui/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,11 @@
1616
"@types/node": "^22.15.3",
1717
"@types/react": "19.1.0",
1818
"@types/react-dom": "19.1.1",
19-
"eslint": "^9.34.0",
19+
"eslint": "^9.38.0",
2020
"typescript": "5.9.2"
2121
},
2222
"dependencies": {
23-
"react": "^19.1.0",
23+
"react": "^19.2.0",
2424
"react-dom": "^19.1.0"
2525
}
2626
}

0 commit comments

Comments
 (0)