Skip to content

Commit

Permalink
Merge pull request #95 from Exabyte-io/feat/SOF-6399
Browse files Browse the repository at this point in the history
SOF-6399: add eslint preset
  • Loading branch information
unsigned6 committed Nov 22, 2022
2 parents bb9507e + 0632a30 commit 9695509
Show file tree
Hide file tree
Showing 60 changed files with 1,441 additions and 716 deletions.
2 changes: 1 addition & 1 deletion .babelrc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
}
}
],
"@babel/preset-react",
"@babel/preset-react"
],
"plugins": [
"@babel/plugin-proposal-class-properties"
Expand Down
57 changes: 3 additions & 54 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,60 +1,9 @@
{
"extends": ["airbnb", "prettier", "eslint:recommended", "plugin:react/recommended"],
"settings": {
"import/resolver": {
"node": {
"paths": ["src"]
}
}
},
"parser": "@babel/eslint-parser",
"env": {
"browser": true,
"node": true
},
"plugins": ["react", "prettier", "simple-import-sort", "jsdoc"],
"extends": ["@exabyte-io/eslint-config", "plugin:react/recommended"],
"plugins": ["react"],
"rules": {
"react/jsx-filename-extension": "error",
"jsx-a11y/label-has-associated-control": ["error", { "assert": "either" }],
"prettier/prettier": "error",
"comma-dangle": ["error", "always-multiline"],
"array-element-newline": ["error", "consistent"],
"no-plusplus": ["error", { "allowForLoopAfterthoughts": true }],
"one-var": ["error", { "uninitialized": "always", "initialized": "never" }],
"brace-style": ["error", "1tbs", { "allowSingleLine": true }],
"prefer-template": "off",
"camelcase": "off",
"max-len": "off",
"no-console": "off",
"no-unused-expressions": "warn",
"react/forbid-prop-types": "warn",
"no-confusing-arrow": "off",
"no-underscore-dangle": "off",
"no-return-assign": "off",
"consistent-return": "off",
"arrow-body-style": "off",
"import/prefer-default-export": "off",
"import/no-named-as-default-member": "warn",
"no-param-reassign": ["warn", { "props": false }],
"max-classes-per-file": "warn",
"simple-import-sort/imports": [
"warn",
{
"groups": [
// Side effect imports.
["^\\u0000"],
// Packages.
// Things that start with a letter (or digit or underscore), or `@` followed by a letter.
["^@?\\w"],
// Absolute imports
[
"^(components|configs|constants|containers|domain|enhancers|hocs|libs|pages|reducers|services|store|modules|dictionaries)(/.*|$)"
],
// Relative imports.
// Anything that starts with a dot.
["^\\."]
]
}
]
"react/forbid-prop-types": "warn"
}
}
10 changes: 6 additions & 4 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ concurrency:
jobs:

run-tests:
runs-on: ubuntu-latest
runs-on: ubuntu-20.04

steps:
- name: Checkout this repository
Expand All @@ -25,15 +25,17 @@ jobs:
token: ${{ secrets.BOT_GITHUB_TOKEN }}
path: actions

- name: Validate JS package
uses: ./actions/js/validate
with:
node-version: 12.21.x

- name: Docker build and test
uses: ./.github/workflows/docker-build-test
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_ECR }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_ECR }}

- name: Validate JS package
uses: ./actions/js/validate

- name: Validate app dockerfile
uses: ./actions/docker/validate
with:
Expand Down
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
tests/cucumber/fixtures/*.json
Loading

0 comments on commit 9695509

Please sign in to comment.