Skip to content
This repository has been archived by the owner on Feb 8, 2024. It is now read-only.

Commit

Permalink
ESLint support (#1119)
Browse files Browse the repository at this point in the history
* eslint integration

* configure the rules and warnings

* update ci script
  • Loading branch information
Denys Vuika authored May 28, 2021
1 parent 2df3084 commit c48f6bb
Show file tree
Hide file tree
Showing 9 changed files with 965 additions and 9 deletions.
8 changes: 8 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# don't ever lint node_modules
node_modules
# don't lint build output (make sure it's set to your correct build folder name)
dist
# don't lint nyc coverage output
coverage

test/performance
32 changes: 32 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
module.exports = {
root: true,
env: {
node: true,
browser: true
},
parser: '@typescript-eslint/parser',
plugins: [
'@typescript-eslint',
],
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
],
// TODO: consider removing these rules and improving the source code
rules: {
'prefer-const': 1,
'no-useless-escape': 1,
'prefer-rest-params': 1,
'prefer-spread': 1,
'no-prototype-builtins': 1,
'@typescript-eslint/explicit-module-boundary-types': 1,
'@typescript-eslint/ban-ts-comment': 1,
'@typescript-eslint/ban-types': 1,
'@typescript-eslint/no-var-requires': 1,
'@typescript-eslint/no-explicit-any': 1,
'@typescript-eslint/no-empty-function': 1,
'@typescript-eslint/no-namespace': 1,
'@typescript-eslint/no-inferrable-types': 1,
'@typescript-eslint/no-unused-vars': 1
}
};
Loading

0 comments on commit c48f6bb

Please sign in to comment.