forked from ToolJet/ToolJet
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix linting errors across the app (ToolJet#785)
* eslint-setup: rules for frontend and server * setup pre-commit:hook * frontend:eslint fixes * frontend eslint errors and warning fixed * eslint:fix for ./server * fix server/test: expectatin string lint/error * pre-commit:updated * removed unwanted install cmd from docker file * recommended settings and extension for vscode * husky prepare script added * updated extension recommendations * added prettier as recommended extension * added pre-commit to package.json * remove .prettierrc file * resolve changes * resolve changes
- Loading branch information
Showing
263 changed files
with
7,833 additions
and
5,409 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"recommendations": [ | ||
"dbaeumer.vscode-eslint", | ||
"CoenraadS.bracket-pair-colorizer", | ||
"mgmcdermott.vscode-language-babel", | ||
"formulahendry.auto-rename-tag", | ||
"xabikos.javascriptsnippets", | ||
"streetsidesoftware.code-spell-checker", | ||
"esbenp.prettier-vscode" | ||
] | ||
} |
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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"[javascript, typescript]": { | ||
"editor.defaultFormatter": "dbaeumer.vscode-eslint", | ||
}, | ||
"eslint.validate": [ | ||
"javascript", | ||
"javascriptreact", | ||
"typescript", | ||
"typescriptreact" | ||
], | ||
"eslint.format.enable": true, | ||
"editor.formatOnSave": true, | ||
|
||
} |
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
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,56 @@ | ||
{ | ||
"env": { | ||
"browser": true, | ||
"amd": true, | ||
"es2021": true | ||
}, | ||
"extends": [ | ||
"eslint:recommended", | ||
"plugin:react/recommended", | ||
"plugin:react-hooks/recommended", | ||
"plugin:import/errors", | ||
"plugin:import/warnings", | ||
"plugin:prettier/recommended", | ||
"plugin:cypress/recommended" | ||
], | ||
"parser": "babel-eslint", | ||
"parserOptions": { | ||
"ecmaFeatures": { | ||
"jsx": true | ||
}, | ||
"ecmaVersion": 12, | ||
"sourceType": "module" | ||
}, | ||
"plugins": ["react", "prettier"], | ||
"rules": { | ||
"prettier/prettier": [ | ||
"error", | ||
{ | ||
"semi": true, | ||
"trailingComma": "es5", | ||
"printWidth": 120, | ||
"singleQuote": true, | ||
"arrowParens": "always", | ||
"proseWrap": "preserve" | ||
} | ||
], | ||
"react/prop-types": 0, | ||
"react/display-name": "off", | ||
"no-unused-vars": [2, { "args": "after-used", "argsIgnorePattern": "reject" }], | ||
"react/no-deprecated": 0, | ||
"no-prototype-builtins": 0 | ||
}, | ||
"settings": { | ||
"react": { | ||
"version": "detect" | ||
}, | ||
"import/resolver": "webpack" | ||
}, | ||
"globals": { | ||
"fetch": true, | ||
"process": true, | ||
"module": true, | ||
"__dirname": true | ||
} | ||
} | ||
|
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,16 +1,12 @@ | ||
const webpackPreprocessor = require('@cypress/webpack-preprocessor') | ||
|
||
module.exports = (on, config) => { | ||
if (config.testingType === 'component') { | ||
const { startDevServer } = require('@cypress/webpack-dev-server') | ||
const { startDevServer } = require('@cypress/webpack-dev-server'); | ||
|
||
// Your project's Webpack configuration | ||
const webpackConfig = require('../../webpack.config.js') | ||
const webpackConfig = require('../../webpack.config.js'); | ||
|
||
on('dev-server:start', (options) => | ||
startDevServer({ options, webpackConfig }) | ||
) | ||
on('dev-server:start', (options) => startDevServer({ options, webpackConfig })); | ||
} | ||
|
||
return config | ||
} | ||
return config; | ||
}; |
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
Oops, something went wrong.