Migrate to eslint#67
Conversation
1 similar comment
|
@kezhenxu94 I turned off individual rules, |
What do you mean "turned off individual rules", after that how many rules and what are enabled? |
|
Two rules are turned off, one for method parameters not being used, and the other for regular no-useless-escape,the only manually enabled rule is file-header, the rest are eslint:recommend enabled rules This is the modified rule configmodule.exports = {
extends: ["eslint:recommended", "plugin:prettier/recommended"],
plugins: ["header"],
parser: "@typescript-eslint/parser",
parserOptions: {
sourceType: "module"
},
rules: {
"header/header": ["error", ".file-headerrc"],
"no-useless-escape": "off",
"no-unused-vars": [
"error",
// we are only using this rule to check for unused arguments since TS
// catches unused variables but not args.
{ varsIgnorePattern: ".*", args: "none" }
]
},
env: {
node: true
}
}; |
This is acceptable to me |
|
Can you adjust the rules to minimize the changes, if we can change 366 lines to pass the check, we can do that first |
Thanks for looking into this, we can remove the lint command in CI for node 10, we can even only run lint in node 14 as the lint result doesn't rely on node version. Can you try to add an if condition in that CI file? You can refer to https://github.com/apache/skywalking/blob/c548b00517a5f305d3a98dbdfdc81525aa82f0f7/.github/workflows/ci-it.yaml#L82 to see the Happy Chinese New Year!! @ruleeeer 🎉 |
kezhenxu94
left a comment
There was a problem hiding this comment.
Thank you @ruleeeer very much!






@kezhenxu94 hey,this part is already done, I only added a few rules to the eslint configuration (don't worry, it contains important file header rules) because I just started contributing and I'm not sure which rules you need