Skip to content

Commit

Permalink
Merge pull request #175 from ZzqiZQute/feat/eslint
Browse files Browse the repository at this point in the history
feat: 添加ESLint
  • Loading branch information
wangxinleo authored Sep 20, 2022
2 parents 262edbc + 6895695 commit 240acf0
Show file tree
Hide file tree
Showing 14 changed files with 4,944 additions and 1,737 deletions.
5 changes: 5 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
node_modules
__test__
config
coverage

29 changes: 29 additions & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
module.exports = {
env: {
node: true,
es2021: true,
},
extends: 'airbnb-base',
globals: {
expect: 'readonly',
test: 'readonly',
describe: 'readonly'
},
overrides: [
],
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
},
rules: {
'no-console': 0,
'import/no-extraneous-dependencies': 0,
'import/extensions': 0,
'max-len': 0,
'semi': [2, 'never'],
'no-param-reassign': 0,
'no-restricted-syntax': 0,
'no-plusplus': 0,
'no-await-in-loop': 0
},
};
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

lint-staged
Loading

0 comments on commit 240acf0

Please sign in to comment.