Skip to content
Draft
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
23 changes: 23 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
import { defineConfig } from "eslint/config";
import nextVitals from "eslint-config-next/core-web-vitals";
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The import statement uses a non-standard path. According to the package.json, the package is "eslint-config-next", so the import should be:

import nextVitals from "eslint-config-next";

Not "eslint-config-next/core-web-vitals". While this may work with some configurations, the standard ESLint 9 flat config for Next.js should import the package directly.

Suggested change
import nextVitals from "eslint-config-next/core-web-vitals";
import nextVitals from "eslint-config-next";

Copilot uses AI. Check for mistakes.

import prettierConfig from "eslint-config-prettier";
import prettierPlugin from "eslint-plugin-prettier";
import unusedImports from "eslint-plugin-unused-imports";

export default defineConfig([
Comment on lines +1 to +8
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The import statement uses defineConfig from "eslint/config", but this should be imported from "eslint-define-config" package or removed entirely. ESLint 9 flat config doesn't require a defineConfig wrapper - you can export the array directly. The correct approach for ESLint 9 is:

export default [
  nextVitals,
  prettierConfig,
  // ...
];

Copilot uses AI. Check for mistakes.
nextVitals,
prettierConfig,

{
plugins: {
prettier: prettierPlugin,
"unused-imports": unusedImports,
},
rules: {
"prettier/prettier": "warn",
"unused-imports/no-unused-imports": "warn",
"unused-imports/no-unused-vars": "warn",
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The rule "unused-imports/no-unused-vars" is configured, but in the old .eslintrc.json this rule was not present - only "unused-imports/no-unused-imports" was configured. This adds a new linting rule that may cause unexpected warnings. Consider whether this additional rule is intentional or should be removed to maintain consistency with the previous configuration.

Suggested change
"unused-imports/no-unused-vars": "warn",

Copilot uses AI. Check for mistakes.
},
},
]);
Comment on lines +1 to +23
Copy link

Copilot AI Dec 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The old ESLint configuration file .eslintrc.json should be deleted since this PR migrates to ESLint 9's flat config format. Having both configuration files present could cause confusion and unexpected behavior.

Copilot uses AI. Check for mistakes.
5 changes: 5 additions & 0 deletions next.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ const nextConfig = {
},
// Configure assetPrefix or else the server won't properly resolve your assets.
assetPrefix: isProd ? null : `http://${internalHost}:3000`,
// use reactCompiler for better performance
reactCompiler: true,
devIndicators: false,
experimental: {
turbopackFileSystemCacheForDev: true,
},
};

// Now can run `ANALYZE=true npm run build` to analyze frontend bundle size
Expand Down
Loading
Loading