Skip to content

chore: migrate to flat config - #1724

Merged
danielroe merged 5 commits into
mainfrom
chore/migrate-flat-config
Feb 4, 2026
Merged

danielroe merged 5 commits into
mainfrom
chore/migrate-flat-config

Conversation

@wattanx

@wattanx wattanx commented Feb 2, 2026

Copy link
Copy Markdown
Collaborator

🔗 Linked issue

❓ Type of change

  • 📖 Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • 👌 Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

📚 Description

Migrate ESLint configuration from legacy .eslintrc format to the new flat config format (eslint.config.mjs).
@nuxtjs/eslint-config-typescript does not support flat config.
I manually added equivalent rules to support them.

📝 Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@pkg-pr-new

pkg-pr-new Bot commented Feb 2, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

npm i https://pkg.pr.new/@nuxt/bridge@1724
npm i https://pkg.pr.new/@nuxt/bridge-schema@1724

commit: ecb8b61

@wattanx
wattanx force-pushed the chore/migrate-flat-config branch 2 times, most recently from b730695 to 13cb2e8 Compare February 3, 2026 01:19
@wattanx
wattanx force-pushed the chore/migrate-flat-config branch from 13cb2e8 to 469e1ef Compare February 3, 2026 01:23
Comment thread package.json
Comment on lines +57 to +58
"espree": "11.1.0",
"eslint-visitor-keys": "5.0.0"

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Adding this because provenance-action is failing.

@wattanx
wattanx marked this pull request as ready for review February 3, 2026 01:44
@coderabbitai

coderabbitai Bot commented Feb 3, 2026

Copy link
Copy Markdown
📝 Walkthrough

Walkthrough

This pull request migrates the project's ESLint configuration from the legacy JSON-based format (.eslintrc) to the new ESLint flat config format (eslint.config.mjs). The changes include upgrading ESLint from version 8.57.1 to 9.39.2, removing the @nuxtjs/eslint-config-typescript dependency, and adding new ESLint plugins (neostandard, typescript-eslint, unicorn, and vue). The .eslintignore patterns have been reorganized, and lint-disable comments have been removed or added to reflect rule changes between the old and new configurations.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~50 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title 'chore: migrate to flat config' directly and accurately summarizes the main change of migrating ESLint configuration from legacy .eslintrc to the new flat config format (eslint.config.mjs).
Description check ✅ Passed The description clearly explains the change: migrating ESLint configuration from legacy .eslintrc format to flat config format, noting that @nuxtjs/eslint-config-typescript does not support flat config and equivalent rules were manually added.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/migrate-flat-config

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@package.json`:
- Line 15: The package.json "engines" field is too permissive for our linting
toolchain; update the "engines" entry in package.json to require Node 18.18.0 or
newer by changing it to: node: ^18.18.0 || ^20.9.0 || >=21.1.0 so local
contributors and dependency managers see the correct minimum Node version for
ESLint 9 / typescript-eslint 8; ensure package.json is the file you edit and
commit the updated engines string.

Comment thread package.json
"dev:preview": "node ./playground/.output/server/index.mjs",
"dev:prepare": "pnpm build:stub && nuxi prepare playground",
"lint": "eslint --ext .vue,.ts,.js,.mjs .",
"lint": "eslint .",

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🌐 Web query:

ESLint 9.x minimum Node.js version requirements

💡 Result:

For ESLint 9.x, the minimum supported Node.js version is 18.18.0.

ESLint 9 supports these Node.js versions/ranges: ^18.18.0, ^20.9.0, or >=21.1.0 (and drops Node <18.18 and Node 19). [1], [2]

Sources:
[1] ESLint “Migrate to v9.x” guide. (eslint.org)
[2] ESLint v9.0.0 release post. (eslint.org)

Citations:


🌐 Web query:

typescript-eslint 8.x minimum Node.js version requirements

💡 Result:

typescript-eslint v8.x requires Node.js in this supported range:

  • ^18.18.0 || ^20.9.0 || >=21.1.0 → practical minimum is Node 18.18.0 (or 20.9.0+, or 21.1.0+). [1][2]

Sources: dependency version policy page [1] and the v8 announcement (which notes the bump to that Node range) [2].


🏁 Script executed:

# Read the full package.json to see the engines field and dependencies
cat package.json

Repository: nuxt/bridge

Length of output: 2062


🏁 Script executed:

# Check CI workflows for Node versions
find .github/workflows -type f \( -name "*.yml" -o -name "*.yaml" \) -exec cat {} \;

Repository: nuxt/bridge

Length of output: 10883


Update engines field to match ESLint 9 and typescript-eslint 8 Node requirements.

ESLint 9.39.2 and typescript-eslint 8.54.0 require Node 18.18.0 or higher, but engines currently permits Node 14.16+ and 16.11+. This creates a mismatch: contributors using Node 14 or 16 will encounter tooling failures when linting. Update engines to "node": "^18.18.0 || ^20.9.0 || >=21.1.0" to reflect the actual minimum supported version. (Note: CI already runs modern LTS and includes an installed-check validation step, but the declared engines range must be accurate for end users and dependency managers.)

🤖 Prompt for AI Agents
In `@package.json` at line 15, The package.json "engines" field is too permissive
for our linting toolchain; update the "engines" entry in package.json to require
Node 18.18.0 or newer by changing it to: node: ^18.18.0 || ^20.9.0 || >=21.1.0
so local contributors and dependency managers see the correct minimum Node
version for ESLint 9 / typescript-eslint 8; ensure package.json is the file you
edit and commit the updated engines string.

@wattanx
wattanx requested a review from danielroe February 3, 2026 02:20
@danielroe
danielroe merged commit 483aeff into main Feb 4, 2026
78 of 79 checks passed
@danielroe
danielroe deleted the chore/migrate-flat-config branch February 4, 2026 13:09
@github-actions github-actions Bot mentioned this pull request Feb 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants