-
Notifications
You must be signed in to change notification settings - Fork 11
Add block files to Eslint configuration file #184
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
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.
Pull Request Overview
Small change: added a files array to the generated ESLint config to include many file extensions (js/jsx/ts/tsx/mjs/cjs/vue). No Codacy issues were raised. Review focuses on correctness, maintainability, and potential missing extensions or escaping concerns.
About this PR
Good to restrict rules to specific file types. Ensure this list matches the project's actual source file types (e.g., .jsx/.tsx usage, .mjs/.cjs presence). Consider centralizing the extensions list if used elsewhere to avoid duplication.
Low risk | High confidence
💡 Codacy uses AI. Check for mistakes.
| func CreateEslintConfig(toolsConfigDir string, configuration []domain.PatternConfiguration) error { | ||
| result := `export default [ | ||
| { | ||
| files: ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx", "**/*.mjs", "**/*.cjs", "**/*.vue"], |
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.
[Suggestion] You added files: ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx", "**/*.mjs", "**/*.cjs", "**/*.vue"]. Confirm that: (1) you want to include both .mjs and .cjs (commonjs vs ESM) — including both is fine but unnecessary if your repo uses only one; (2) any other extensions (e.g. .cts/.mts, .jsx in .tsx projects, or framework specific extensions) are not needed. If this list may grow, extract into a constant or a small helper to keep the template string clearer.
Medium risk | Medium confidence
Codacy's Analysis Summary0 new issue (≤ 1 medium issue) Review Pull Request in Codacy →
|
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferences |
No description provided.