monkeytype/.eslintrc.json
Rizwan Mustafa 1877cc31e7
(Draft) Replace Browserify with Webpack (Draft) (#2461) by rizwanmustafa
* Replaced browserify with webpack

* Modified gulpfile and webpack config

* Removed attempts of using undefined variables and functions

* fixed some incorrect changes

* setfunbox fix

* Added fallback for crypto-browserify and stream-browserify

* added circular dependency detection

* Created production tasks for gulp and updated webpack config

* fixed circular dependency in misc

* not failing on circular dependency

* Removed unused imports

* Added babel loader and plugins to webpack

* Removed unused dependencies and removed babel's plugins

* Workaround for test logic import in random quote

* Created a separate webpack config file for production

* Changed relative paths to absolute ones in webpack

* Added colored output for circular import number

* Removed comment from .eslintrc.json

* Added eslint plugin to webpack

* Moved 'buffer' and 'stream-browserify' to devDependencies

* Started using promises in webpack tasks

* Removed unused dependencies

* Updated package-lock.json

* Removed eslint plugin from webpack and added circular dependency detection in dev config as well

* Removed unrelated changes

* Updated production build command

* Added ability for webpack to be run with typescript conversion of project in process

* added gulp typscript dev dependency

* using const

* modified console logs on circular imports

* missing dev dependency

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-02-12 14:47:36 +01:00

79 lines
2 KiB
JSON

{
"env": {
"browser": true,
"es2021": true,
"node": true
},
"globals": {
"firebase": "readonly",
"$": "readonly",
"moment": "readonly",
"jQuery": "readonly",
"html2canvas": "readonly",
"ClipboardItem": "readonly",
"grecaptcha": "readonly"
},
"extends": [
"eslint:recommended",
"plugin:json/recommended",
"plugin:require-path-exists/recommended",
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
],
"plugins": ["json", "require-path-exists", "@typescript-eslint"],
"parserOptions": {
"ecmaVersion": 12,
"sourceType": "module"
},
// "parser": "@typescript-eslint/parser",
"rules": {
"json/*": ["error"],
"indent": ["off"],
"linebreak-style": ["error", "unix"],
"quotes": [
"error",
"double",
{ "allowTemplateLiterals": true, "avoidEscape": true }
],
"semi": ["error", "always"],
"no-empty": ["error", { "allowEmptyCatch": true }],
"no-unused-vars": ["error", { "argsIgnorePattern": "^(_|e|event)" }],
"no-var": 2,
"require-path-exists/notEmpty": 2,
"require-path-exists/tooManyArguments": 2,
"require-path-exists/exists": [
2,
{
"extensions": [
"",
".js",
".ts",
".tsx",
".es.ts",
".tsx",
".json5",
".es",
".es6",
".coffee"
]
}
],
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-var-requires": "off"
},
"overrides": [
{
// enable the rule specifically for TypeScript files
"files": ["*.ts", "*.tsx"],
"rules": {
"@typescript-eslint/explicit-function-return-type": ["error"],
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/no-empty-function": "error",
"@typescript-eslint/no-unused-vars": "error",
"@typescript-eslint/no-var-requires": "error"
}
}
]
}