-
Notifications
You must be signed in to change notification settings - Fork 34
build: convert eslint.config to typescript and add our plugin #1112
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This change migrates the eslint config to typescript, and adds our plugin's recommended config.
6ecce3a to
45cbec5
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1112 +/- ##
=======================================
Coverage 99.68% 99.68%
=======================================
Files 22 22
Lines 1564 1564
Branches 205 205
=======================================
Hits 1559 1559
Misses 5 5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This change migrates the eslint config to typescript, and adds our plugin's recommended config.
|
@JoshuaKGoldberg You mentioned some warnings that you weren't a fan of (a reason to maybe wait until the next node release). What warnings were you talking about? ESLint's typescript config support relies on |
| const eslint = new ESLint({ | ||
| baseConfig: plugin.configs.recommended as Linter.Config, | ||
| fix: true, | ||
| overrideConfigFile: true, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was necessary after adding our plugin to the root config. Without this, eslint was using our config in the root as part of this test (which wasn't really good to begin with)
| "eslint-plugin-regexp": "2.8.0", | ||
| "eslint-plugin-yml": "1.18.0", | ||
| "husky": "9.1.7", | ||
| "jiti": "^2.4.2", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I bet after a while we'll be able to drop this too.
Exactly: the warnings aren't there when tools like ESLint use runners/transpilers such as echo "console.log(123)" > index.ts
node index.ts👍 that that's not an issue here since the PR has ESLint using |
JoshuaKGoldberg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🙌 Great!
|
🎉 This is included in version v0.40.0 🎉 The release is available on: Cheers! 📦🚀 |
PR Checklist
status: accepting prsOverview
This change migrates the eslint config to typescript, and adds our plugin's recommended config.
Tested locally to verify our plugin is working as expected. (This'll be great as an e2e smoke test)