Skip to content
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

enhance: reporting tool enhancements and fixes #2176

Closed
wants to merge 6 commits into from
Closed
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
9 changes: 9 additions & 0 deletions reports/.editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
root = true

[*]
indent_style = space
indent_size = 2
end_of_line = auto
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
55 changes: 0 additions & 55 deletions reports/.eslintrc.js

This file was deleted.

43 changes: 43 additions & 0 deletions reports/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
{
"extends": [
"next/core-web-vitals",
"next",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended"
],
"plugins": ["prettier", "import", "@typescript-eslint"],
"rules": {
"prettier/prettier": "error",
"import/order": [
"error",
{
"groups": [
"builtin",
"external",
"internal",
"parent",
"sibling",
"index"
],
"alphabetize": {
"order": "asc",
"caseInsensitive": true
},
"newlines-between": "always"
}
],
"@typescript-eslint/no-unused-vars": [
"warn",
{ "argsIgnorePattern": "^_" }
],
"react/react-in-jsx-scope": "off",
"react/jsx-uses-react": "off"
},
Comment on lines +9 to +35
Copy link

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion

Comprehensive rule set with room for flexibility.

The rules section is well-thought-out, particularly the detailed import order configuration and the TypeScript unused vars warning. The React rule adjustments are spot-on for modern React development.

However, setting "prettier/prettier": "error" might be a bit strict. Consider changing it to "warn" to prevent blocking commits due to minor formatting issues:

-    "prettier/prettier": "error",
+    "prettier/prettier": "warn",

This change would maintain code style while allowing for more flexibility in the development process.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"rules": {
"prettier/prettier": "error",
"import/order": [
"error",
{
"groups": [
"builtin",
"external",
"internal",
"parent",
"sibling",
"index"
],
"alphabetize": {
"order": "asc",
"caseInsensitive": true
},
"newlines-between": "always"
}
],
"@typescript-eslint/no-unused-vars": [
"warn",
{ "argsIgnorePattern": "^_" }
],
"react/react-in-jsx-scope": "off",
"react/jsx-uses-react": "off"
},
"rules": {
"prettier/prettier": "warn",
"import/order": [
"error",
{
"groups": [
"builtin",
"external",
"internal",
"parent",
"sibling",
"index"
],
"alphabetize": {
"order": "asc",
"caseInsensitive": true
},
"newlines-between": "always"
}
],
"@typescript-eslint/no-unused-vars": [
"warn",
{ "argsIgnorePattern": "^_" }
],
"react/react-in-jsx-scope": "off",
"react/jsx-uses-react": "off"
},

"settings": {
"import/resolver": {
"node": {
"extensions": [".js", ".jsx", ".ts", ".tsx"]
}
}
}
}
8 changes: 8 additions & 0 deletions reports/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"semi": true,
"singleQuote": true,
"trailingComma": "all",
"printWidth": 80,
"tabWidth": 2,
"endOfLine": "auto"
}
8 changes: 0 additions & 8 deletions reports/.prettierrc.js

This file was deleted.

7 changes: 0 additions & 7 deletions reports/babel.config.js

This file was deleted.

Loading
Loading