Skip to content

Eslint fixes for the project #987

Description

@anikethsaha

After adding eslint, if your run npx eslint . it will show huge number of errors and warning.

This issue is to fix those errors and warning and remove/add eslint rules if required after discussing here.

Also, eslint script and .eslintignore should be configured as follows.

package.json

"lint": "eslint . --fix",

.eslintrc

{
"extends": "xo-space/browser",
"rules": {
"semi": [2, "never"],
"no-return-assign": "off",
"no-unused-expressions": "off",
"no-new-func": "off",
"no-multi-assign": "off",
"no-mixed-operators": "off",
"max-params": "off",
"no-script-url": "off",
"camelcase": "off",
"object-curly-spacing": "off",
"no-warning-comments": "off",
"no-negated-condition": "off",
"eqeqeq": "warn",
"no-eq-null": "warn",
"max-statements-per-line": "warn"
},
"globals": {
"Docsify": true,
"$docsify": true,
"process": true
},
"env": {
"browser": true,
"amd": true,
"node": true
}
}
  • Npm script fix
  • .eslintrc refactore
  • Errors fix
  • Warning fix
  • add the linting to travis

Contributions are welcome

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions