Skip to content

Commit cf27885

Browse files
Copilotnwalters512
andauthored
Upgrade to Next.js 16 with Turbopack (#192)
* Initial plan * Upgrade to Next.js 16 with Turbopack and all dependencies Co-authored-by: nwalters512 <[email protected]> * Fix ESLint config and remove deprecated --ext flag Co-authored-by: nwalters512 <[email protected]> * Final validation complete - all dependencies upgraded Co-authored-by: nwalters512 <[email protected]> * Fix formatting for next-env.d.ts Co-authored-by: nwalters512 <[email protected]> * Remove unnecessary @eslint/eslintrc dependency and empty next.config.ts Co-authored-by: nwalters512 <[email protected]> * Add GitHub Actions workflow for linting and type checking Co-authored-by: nwalters512 <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: nwalters512 <[email protected]>
1 parent c2f6631 commit cf27885

File tree

7 files changed

+1106
-465
lines changed

7 files changed

+1106
-465
lines changed

.eslintrc

Lines changed: 0 additions & 3 deletions
This file was deleted.

.github/workflows/lint.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Lint
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
lint:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout code
15+
uses: actions/checkout@v4
16+
17+
- name: Setup Node.js
18+
uses: actions/setup-node@v4
19+
with:
20+
node-version: "20"
21+
22+
- name: Enable Corepack
23+
run: corepack enable
24+
25+
- name: Install dependencies
26+
run: yarn install --immutable
27+
28+
- name: Run TypeScript type check
29+
run: yarn tsc --noEmit
30+
31+
- name: Run linting
32+
run: yarn lint

eslint.config.mjs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import nextConfig from "eslint-config-next"
2+
3+
const eslintConfig = [
4+
{
5+
ignores: [".yarn/**", ".next/**", "node_modules/**"],
6+
},
7+
...nextConfig,
8+
]
9+
10+
export default eslintConfig

next-env.d.ts

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/pages/api-reference/config/typescript for more information.

package.json

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -8,28 +8,28 @@
88
"@tailwindcss/postcss": "^4.0.6",
99
"@types/fs-extra": "^11.0.4",
1010
"@types/js-yaml": "^4.0.9",
11-
"@types/react": "^19.0.8",
12-
"autoprefixer": "^10.4.20",
11+
"@types/react": "^19.0.10",
12+
"autoprefixer": "^10.4.21",
1313
"classnames": "^2.5.1",
1414
"fs-extra": "^11.3.0",
1515
"husky": "^9.1.7",
1616
"js-yaml": "^4.1.0",
17-
"next": "^15.1.7",
18-
"postcss": "^8.5.2",
17+
"next": "^16.0.1",
18+
"postcss": "^8.5.3",
1919
"postcss-import": "^16.1.0",
20-
"prettier": "3.5.0",
20+
"prettier": "^3.5.5",
2121
"pretty-quick": "^4.0.0",
2222
"react": "^19.0.0",
2323
"react-dom": "^19.0.0",
2424
"tailwindcss": "^4.0.6",
25-
"typescript": "^5.7.3"
25+
"typescript": "^5.8.0"
2626
},
2727
"license": "MIT",
2828
"scripts": {
29-
"build": "tsc && next build",
30-
"dev": "next dev",
31-
"format": "next lint --fix && prettier --write \"**/*.{js,jsx,ts,tsx,json,md}\"",
32-
"lint": "next lint && prettier --check \"**/*.{js,jsx,ts,tsx,json,md}\"",
29+
"build": "tsc && next build --turbo",
30+
"dev": "next dev --turbo",
31+
"format": "eslint . --fix && prettier --write \"**/*.{js,jsx,ts,tsx,json,md}\"",
32+
"lint": "eslint . && prettier --check \"**/*.{js,jsx,ts,tsx,json,md}\"",
3333
"start": "next start",
3434
"prepare": "husky install"
3535
},
@@ -38,9 +38,9 @@
3838
"url": "https://github.com/nwalters512/cookbook"
3939
},
4040
"devDependencies": {
41-
"@types/node": "22.13.1",
42-
"eslint": "^9.20.1",
43-
"eslint-config-next": "^15.1.7"
41+
"@types/node": "^22.13.10",
42+
"eslint": "^9.20.2",
43+
"eslint-config-next": "^16.0.1"
4444
},
4545
"packageManager": "[email protected]"
4646
}

tsconfig.json

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"compilerOptions": {
3-
"target": "es5",
3+
"target": "ES2020",
44
"lib": ["dom", "dom.iterable", "esnext"],
55
"allowJs": true,
66
"skipLibCheck": true,
@@ -9,11 +9,14 @@
99
"noEmit": true,
1010
"esModuleInterop": true,
1111
"module": "esnext",
12-
"moduleResolution": "node",
12+
"moduleResolution": "bundler",
1313
"resolveJsonModule": true,
1414
"isolatedModules": true,
15-
"jsx": "preserve",
16-
"incremental": true
15+
"jsx": "react-jsx",
16+
"incremental": true,
17+
"paths": {
18+
"@/*": ["./src/*"]
19+
}
1720
},
1821
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx"],
1922
"exclude": ["node_modules"]

0 commit comments

Comments
 (0)