Skip to content

Commit

Permalink
Merge pull request #30 from square/eslint
Browse files Browse the repository at this point in the history
Add eslint linting
  • Loading branch information
bmish authored Jun 11, 2020
2 parents 0ed9774 + 73caebb commit 246d7e2
Show file tree
Hide file tree
Showing 4 changed files with 682 additions and 7 deletions.
18 changes: 18 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
module.exports = {
extends: [
'eslint:recommended'
],
env: {
node: true
},
parserOptions: {
ecmaVersion: 2018,
sourceType: 'script',
},
overrides: [
{
files: ['tests/**/*.js'],
env: { mocha: true },
},
],
};
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@ jobs:
node-version: ${{ matrix.node-version }}
- run: yarn install --frozen-lockfile --non-interactive
- run: yarn test
- run: yarn lint
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
"author": "Square, Inc.",
"license": "Apache-2.0",
"scripts": {
"lint": "yarn lint:js",
"lint:js": "eslint .",
"test": "mocha tests/**/*-test.js",
"commitmsg": "commitlint -e $GIT_PARAMS"
},
Expand All @@ -24,6 +26,7 @@
"@commitlint/cli": "^5.2.6",
"@commitlint/config-conventional": "^5.2.3",
"chai": "^4.1.2",
"eslint": "^6.8.0",
"husky": "^0.14.3",
"mocha": "^4.0.1",
"standard-version": "^4.2.0"
Expand Down
Loading

0 comments on commit 246d7e2

Please sign in to comment.