-
Notifications
You must be signed in to change notification settings - Fork 298
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
This reverts commit 5041008.
- Loading branch information
1 parent
5041008
commit 7a80c86
Showing
19 changed files
with
185 additions
and
224 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,132 +1,110 @@ | ||
module.exports = { | ||
root: true, | ||
parser: '@babel/eslint-parser', | ||
plugins: ['prettier', 'testing-library'], | ||
env: { | ||
es6: true, | ||
browser: true, | ||
amd: true, | ||
mocha: true, | ||
jest: true, | ||
jquery: true, | ||
jasmine: true, | ||
}, | ||
globals: { | ||
dataLayer: true, | ||
texts_json: false, | ||
}, | ||
rules: { | ||
camelcase: 0, | ||
// semi : ['error', 'always'], | ||
'array-callback-return': 0, | ||
'arrow-body-style': 0, | ||
'brace-style': ['error', '1tbs', { allowSingleLine: true }], | ||
curly: 0, | ||
// 'comma-dangle' : ['error', 'always-multiline'], | ||
'eol-last': ['error', 'always'], | ||
'func-names': ['error', 'never'], | ||
'key-spacing': 0, | ||
'max-classes-per-file': ['warn', 2], | ||
// 'keyword-spacing' : ['error', { after: true }], | ||
'lines-between-class-members': 0, | ||
indent: 0, | ||
// 'max-len' : ['error', { code: 120, 'ignoreComments': true }], | ||
// 'no-extra-semi' : 'error', | ||
'no-console': 'error', | ||
'no-else-return': ['error', { allowElseIf: true }], | ||
'no-multi-assign': 0, | ||
// 'no-multi-spaces' : [2, { exceptions: { 'BinaryExpression': true, 'VariableDeclarator': true, 'ImportDeclaration': true } }], | ||
'no-param-reassign': ['error', { props: false }], | ||
'no-restricted-globals': 0, | ||
'no-script-url': 0, | ||
// 'no-trailing-spaces' : ['error', { skipBlankLines: true }], | ||
// 'object-curly-spacing' : ['error', 'always', { arraysInObjects: true, objectsInObjects: true }], | ||
'one-var': ['error', { initialized: 'never', uninitialized: 'always' }], | ||
'prefer-destructuring': 0, | ||
quotes: 0, | ||
// 'space-in-parens' : ['error', 'never'], | ||
'space-infix-ops': 'error', | ||
// 'space-unary-ops' : 'error', | ||
// 'no-multiple-empty-lines' : ['error', { 'max': 1, 'maxEOF': 1 }], | ||
root: true, | ||
parser: 'babel-eslint', | ||
plugins: ['prettier', 'testing-library'], | ||
env: { | ||
es6: true, | ||
browser: true, | ||
amd: true, | ||
mocha: true, | ||
jest: true, | ||
jquery: true, | ||
jasmine: true, | ||
}, | ||
globals: { | ||
dataLayer: true, | ||
texts_json: false, | ||
}, | ||
rules: { | ||
camelcase: 0, | ||
// semi : ['error', 'always'], | ||
'array-callback-return': 0, | ||
'arrow-body-style': 0, | ||
'brace-style': ['error', '1tbs', { allowSingleLine: true }], | ||
curly: 0, | ||
// 'comma-dangle' : ['error', 'always-multiline'], | ||
'eol-last': ['error', 'always'], | ||
'func-names': ['error', 'never'], | ||
'key-spacing': 0, | ||
'max-classes-per-file': ['warn', 2], | ||
// 'keyword-spacing' : ['error', { after: true }], | ||
'lines-between-class-members': 0, | ||
indent: 0, | ||
// 'max-len' : ['error', { code: 120, 'ignoreComments': true }], | ||
// 'no-extra-semi' : 'error', | ||
'no-console': 'error', | ||
'no-else-return': ['error', { allowElseIf: true }], | ||
'no-multi-assign': 0, | ||
// 'no-multi-spaces' : [2, { exceptions: { 'BinaryExpression': true, 'VariableDeclarator': true, 'ImportDeclaration': true } }], | ||
'no-param-reassign': ['error', { props: false }], | ||
'no-restricted-globals': 0, | ||
'no-script-url': 0, | ||
// 'no-trailing-spaces' : ['error', { skipBlankLines: true }], | ||
// 'object-curly-spacing' : ['error', 'always', { arraysInObjects: true, objectsInObjects: true }], | ||
'one-var': ['error', { initialized: 'never', uninitialized: 'always' }], | ||
'prefer-destructuring': 0, | ||
quotes: 0, | ||
// 'space-in-parens' : ['error', 'never'], | ||
'space-infix-ops': 'error', | ||
// 'space-unary-ops' : 'error', | ||
// 'no-multiple-empty-lines' : ['error', { 'max': 1, 'maxEOF': 1 }], | ||
|
||
// import rules | ||
'import/no-extraneous-dependencies': [ | ||
'error', | ||
{ | ||
devDependencies: [ | ||
'**/__tests__/**/*.js', | ||
'**/test*.js', | ||
'**/*.test.js*', | ||
'**/*.spec.js', | ||
'**/*.spec.jsx', | ||
], | ||
}, | ||
], | ||
// import rules | ||
'import/no-extraneous-dependencies': ['error', { 'devDependencies': ['**/__tests__/**/*.js', '**/test*.js', '**/*.test.js*', '**/*.spec.js', '**/*.spec.jsx'] }], | ||
|
||
'import/no-useless-path-segments': 'error', | ||
'import/order': [ | ||
0, // TODO: we should turn this to error after we sorted our import orders. | ||
{ | ||
groups: [['builtin', 'external'], 'internal', 'sibling', 'parent'], | ||
'newlines-between': 'ignore', | ||
}, | ||
], | ||
'import/prefer-default-export': 0, | ||
'import/extensions': ['warn', 'never', { jsx: 'always', json: 'always' }], | ||
'no-sequences': ['warn'], | ||
'import/no-unresolved': [2, { ignore: ['@deriv/components', '@deriv/shared'] }], | ||
'import/no-useless-path-segments': 'error', | ||
'import/order': [ | ||
0, // TODO: we should turn this to error after we sorted our import orders. | ||
{ | ||
groups: [['builtin', 'external'], 'internal', 'sibling', 'parent'], | ||
'newlines-between': 'ignore', | ||
}, | ||
], | ||
'import/prefer-default-export': 0, | ||
'import/extensions': ['warn', 'never', { jsx: 'always', json: 'always' }], | ||
'no-sequences': ['warn'], | ||
'import/no-unresolved': [ | ||
2, | ||
{ ignore: ['@deriv/components', '@deriv/shared'] }, | ||
], | ||
|
||
// react rules | ||
// 'jsx-quotes' : ['error', 'prefer-single'], | ||
// 'react/jsx-closing-bracket-location': ['error', { selfClosing: 'line-aligned', nonEmpty: 'line-aligned' }], | ||
// 'react/jsx-closing-tag-location' : 'error', | ||
// 'react/jsx-first-prop-new-line' : ['error', 'multiline-multiprop'], | ||
// 'react/jsx-indent' : ['error', 4], | ||
// 'react/jsx-indent-props' : ['error', 4], | ||
// 'react/jsx-max-props-per-line' : ['error', { when: 'multiline' }], | ||
// 'react/jsx-tag-spacing' : ['error', { closingSlash: 'never', beforeSelfClosing: 'always' }], | ||
'react/prop-types': 0, | ||
'react/self-closing-comp': 'error', | ||
// 'react/sort-prop-types' : ['error', { ignoreCase: true, sortShapeProp: true }], | ||
// react rules | ||
// 'jsx-quotes' : ['error', 'prefer-single'], | ||
// 'react/jsx-closing-bracket-location': ['error', { selfClosing: 'line-aligned', nonEmpty: 'line-aligned' }], | ||
// 'react/jsx-closing-tag-location' : 'error', | ||
// 'react/jsx-first-prop-new-line' : ['error', 'multiline-multiprop'], | ||
// 'react/jsx-indent' : ['error', 4], | ||
// 'react/jsx-indent-props' : ['error', 4], | ||
// 'react/jsx-max-props-per-line' : ['error', { when: 'multiline' }], | ||
// 'react/jsx-tag-spacing' : ['error', { closingSlash: 'never', beforeSelfClosing: 'always' }], | ||
'react/prop-types': 0, | ||
'react/self-closing-comp': 'error', | ||
// 'react/sort-prop-types' : ['error', { ignoreCase: true, sortShapeProp: true }], | ||
}, | ||
extends: [ | ||
'prettier', | ||
'prettier/react', | ||
'airbnb-base', | ||
'binary', | ||
'plugin:react/recommended', | ||
'plugin:react-hooks/recommended', | ||
'plugin:jest-dom/recommended', | ||
], | ||
parserOptions: { | ||
ecmaVersion: 6, | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
extends: [ | ||
'prettier', | ||
'prettier/react', | ||
'airbnb-base', | ||
'binary', | ||
'plugin:react/recommended', | ||
'plugin:react-hooks/recommended', | ||
'plugin:jest-dom/recommended', | ||
], | ||
parserOptions: { | ||
requireConfigFile: false, | ||
ecmaVersion: 8, | ||
babelOptions: { | ||
presets: ['@babel/preset-react', '@babel/preset-typescript'], | ||
plugins: [ | ||
['@babel/plugin-proposal-decorators', { legacy: true }], | ||
['@babel/plugin-proposal-class-properties', { loose: true }], | ||
'@babel/plugin-proposal-export-default-from', | ||
'@babel/plugin-proposal-object-rest-spread', | ||
'@babel/plugin-proposal-export-namespace-from', | ||
'@babel/plugin-syntax-dynamic-import', | ||
'@babel/plugin-proposal-optional-chaining', | ||
'@babel/plugin-proposal-nullish-coalescing-operator', | ||
], | ||
}, | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
}, | ||
settings: { | ||
react: { | ||
version: '16', | ||
}, | ||
settings: { | ||
react: { | ||
version: '16', | ||
}, | ||
}, | ||
overrides: [ | ||
{ | ||
files: ['**/__tests__/**/*.[jt]s?(x)', '**/?(*.)+(spec|test).[jt]s?(x)'], | ||
extends: ['plugin:testing-library/react'], | ||
}, | ||
overrides: [ | ||
{ | ||
files: ['**/__tests__/**/*.[jt]s?(x)', '**/?(*.)+(spec|test).[jt]s?(x)'], | ||
extends: ['plugin:testing-library/react'], | ||
}, | ||
], | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
npx lint-staged --allow-empty | ||
npm run prettify |
This file was deleted.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.
7a80c86
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
deriv-app – ./
deriv-app-git-master.binary.sx
binary.sx
deriv-app.binary.sx
deriv-app.vercel.app