chore(deps): upgrade to Next.js 16, Vitest 4, and Node.js 24
BREAKING CHANGES: - Upgrade Next.js from 15.1.6 to 16.0.4 - Use Webpack instead of Turbopack for compatibility with server-side modules - Upgrade Node.js requirement to >=24.0.0 FEATURES: - Upgrade Vitest to 4.0.13 with improved testing capabilities - Update all vitest-related packages (@vitest/ui, @vitest/coverage-v8) - Upgrade react-syntax-highlighter to 16.1.0 - Update node-cron to 4.2.1 - Update lucide-react to 0.554.0 SECURITY: - Resolve glob command injection vulnerability (CVE) via v10.5.0 - Fix all npm audit vulnerabilities (0 vulnerabilities found) - Update prisma/client to 6.19.0 - Update all dependencies to latest secure versions FIXES: - Configure next.config.js for webpack with proper server-side module handling - Update tsconfig.json for Next.js 16 compatibility (jsx: react-jsx) - Add engines field to require Node.js >=24.0.0 - Remove deprecated webpack config in favor of Next.js 16 compatibility
This commit is contained in:
@@ -43,6 +43,10 @@ const config = {
|
||||
'http://192.168.*',
|
||||
],
|
||||
|
||||
turbopack: {
|
||||
// Disable Turbopack and use Webpack instead for compatibility
|
||||
// This is necessary for server-side code that uses child_process
|
||||
},
|
||||
webpack: (config, { dev, isServer }) => {
|
||||
if (dev && !isServer) {
|
||||
config.watchOptions = {
|
||||
@@ -50,12 +54,15 @@ const config = {
|
||||
aggregateTimeout: 300,
|
||||
};
|
||||
}
|
||||
// Handle server-side modules
|
||||
if (isServer) {
|
||||
config.externals = config.externals || [];
|
||||
if (!config.externals.includes('child_process')) {
|
||||
config.externals.push('child_process');
|
||||
}
|
||||
}
|
||||
return config;
|
||||
},
|
||||
// Ignore ESLint errors during build (they can be fixed separately)
|
||||
eslint: {
|
||||
ignoreDuringBuilds: true,
|
||||
},
|
||||
// Ignore TypeScript errors during build (they can be fixed separately)
|
||||
typescript: {
|
||||
ignoreBuildErrors: true,
|
||||
|
||||
2708
package-lock.json
generated
2708
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
29
package.json
29
package.json
@@ -4,11 +4,11 @@
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"build": "next build",
|
||||
"build": "next build --webpack",
|
||||
"check": "next lint && tsc --noEmit",
|
||||
"dev": "next dev",
|
||||
"dev": "next dev --webpack",
|
||||
"dev:server": "node server.js",
|
||||
"dev:next": "next dev",
|
||||
"dev:next": "next dev --webpack",
|
||||
"format:check": "prettier --check \"**/*.{ts,tsx,js,jsx,mdx}\" --cache",
|
||||
"format:write": "prettier --write \"**/*.{ts,tsx,js,jsx,mdx}\" --cache",
|
||||
"lint": "next lint",
|
||||
@@ -22,7 +22,7 @@
|
||||
"typecheck": "tsc --noEmit"
|
||||
},
|
||||
"dependencies": {
|
||||
"@prisma/client": "^6.18.0",
|
||||
"@prisma/client": "^6.19.0",
|
||||
"@radix-ui/react-dropdown-menu": "^2.1.16",
|
||||
"@radix-ui/react-slot": "^1.2.3",
|
||||
"@t3-oss/env-nextjs": "^0.13.8",
|
||||
@@ -43,14 +43,14 @@
|
||||
"cron-validator": "^1.2.0",
|
||||
"dotenv": "^17.2.3",
|
||||
"jsonwebtoken": "^9.0.2",
|
||||
"lucide-react": "^0.553.0",
|
||||
"next": "^15.1.6",
|
||||
"node-cron": "^3.0.3",
|
||||
"lucide-react": "^0.554.0",
|
||||
"next": "^16.0.4",
|
||||
"node-cron": "^4.2.1",
|
||||
"node-pty": "^1.0.0",
|
||||
"react": "^19.0.0",
|
||||
"react-dom": "^19.0.0",
|
||||
"react-markdown": "^10.1.0",
|
||||
"react-syntax-highlighter": "^15.6.6",
|
||||
"react-syntax-highlighter": "^16.1.0",
|
||||
"refractor": "^5.0.0",
|
||||
"remark-gfm": "^4.0.1",
|
||||
"server-only": "^0.0.1",
|
||||
@@ -74,10 +74,10 @@
|
||||
"@types/react": "^19.2.4",
|
||||
"@types/react-dom": "^19.2.2",
|
||||
"@vitejs/plugin-react": "^5.1.0",
|
||||
"@vitest/coverage-v8": "^3.2.4",
|
||||
"@vitest/ui": "^3.2.4",
|
||||
"@vitest/coverage-v8": "^4.0.13",
|
||||
"@vitest/ui": "^4.0.13",
|
||||
"eslint": "^9.39.1",
|
||||
"eslint-config-next": "^15.1.6",
|
||||
"eslint-config-next": "^16.0.4",
|
||||
"jsdom": "^27.2.0",
|
||||
"postcss": "^8.5.3",
|
||||
"prettier": "^3.5.3",
|
||||
@@ -86,13 +86,16 @@
|
||||
"tailwindcss": "^4.1.17",
|
||||
"typescript": "^5.8.2",
|
||||
"typescript-eslint": "^8.46.2",
|
||||
"vitest": "^3.2.4"
|
||||
"vitest": "^4.0.13"
|
||||
},
|
||||
"ct3aMetadata": {
|
||||
"initVersion": "7.39.3"
|
||||
},
|
||||
"packageManager": "npm@10.9.3",
|
||||
"engines": {
|
||||
"node": ">=24.0.0"
|
||||
},
|
||||
"overrides": {
|
||||
"prismjs": "^1.30.0"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -22,7 +22,7 @@
|
||||
"noEmit": true,
|
||||
"module": "ESNext",
|
||||
"moduleResolution": "Bundler",
|
||||
"jsx": "preserve",
|
||||
"jsx": "react-jsx",
|
||||
"plugins": [
|
||||
{
|
||||
"name": "next"
|
||||
|
||||
Reference in New Issue
Block a user