Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(deps): update eslint and prettier (major) #254

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions globals/kintone.js
Expand Up @@ -13,6 +13,6 @@ module.exports = {
Chart: false,
DOMPurify: false,
Spinner: false,
UltraDate: false
}
UltraDate: false,
},
};
52 changes: 26 additions & 26 deletions lib/base.js
Expand Up @@ -3,12 +3,12 @@ module.exports = {
plugins: ["import"],
parserOptions: {
ecmaVersion: 2019,
sourceType: "module"
sourceType: "module",
},
env: {
browser: true,
es6: true,
commonjs: true
commonjs: true,
},
rules: {
// =======
Expand Down Expand Up @@ -38,8 +38,8 @@ module.exports = {
"error",
{
allowShortCircuit: true,
allowTernary: true
}
allowTernary: true,
},
],
"no-useless-concat": "error",
"no-void": "error",
Expand All @@ -64,8 +64,8 @@ module.exports = {
"valid-typeof": [
"error",
{
requireStringLiterals: true
}
requireStringLiterals: true,
},
],
// for-direction
// getter-return
Expand Down Expand Up @@ -103,8 +103,8 @@ module.exports = {
"error",
{
vars: "local",
args: "none"
}
args: "none",
},
],
// no-delete-var
// no-undef
Expand All @@ -114,8 +114,8 @@ module.exports = {
"no-confusing-arrow": [
"error",
{
allowParens: true
}
allowParens: true,
},
],
"no-useless-computed-key": "error",
"no-useless-rename": "error",
Expand Down Expand Up @@ -155,17 +155,17 @@ module.exports = {
"warn",
"always",
{
null: "ignore"
}
null: "ignore",
},
],
"guard-for-in": "warn",
"no-div-regex": "warn",
"no-else-return": "warn",
"no-empty-function": [
"warn",
{
allow: ["arrowFunctions", "functions", "methods"]
}
allow: ["arrowFunctions", "functions", "methods"],
},
],
"no-extra-label": "warn",
"no-invalid-this": "warn",
Expand Down Expand Up @@ -194,8 +194,8 @@ module.exports = {
"warn",
{
destructuring: "all",
ignoreReadBeforeAssign: true
}
ignoreReadBeforeAssign: true,
},
],
"prefer-spread": "warn",
"rest-spread-spacing": "warn",
Expand Down Expand Up @@ -223,8 +223,8 @@ module.exports = {
"warn",
{
max: 2,
maxEOF: 1
}
maxEOF: 1,
},
],
"no-nested-ternary": "warn",
"no-trailing-spaces": "warn",
Expand All @@ -235,17 +235,17 @@ module.exports = {
"object-property-newline": [
"warn",
{
allowAllPropertiesOnSameLine: true
}
allowAllPropertiesOnSameLine: true,
},
],
"one-var-declaration-per-line": "warn",
"operator-assignment": "warn",
quotes: [
"warn",
"single",
{
allowTemplateLiterals: true
}
allowTemplateLiterals: true,
},
],
semi: "warn",
"semi-spacing": "warn",
Expand All @@ -256,8 +256,8 @@ module.exports = {
{
anonymous: "never",
named: "never",
asyncArrow: "always"
}
asyncArrow: "always",
},
],
"space-in-parens": "warn",
"space-infix-ops": "warn",
Expand All @@ -268,7 +268,7 @@ module.exports = {
"unicode-bom": "warn",

// eslint-plugin-import
"import/no-duplicates": "warn"
"import/no-duplicates": "warn",

// =====
// None
Expand Down Expand Up @@ -368,5 +368,5 @@ module.exports = {
// sort-keys
// sort-vars
// wrap-regex
}
},
};
8 changes: 4 additions & 4 deletions lib/es5.js
Expand Up @@ -8,11 +8,11 @@ module.exports = {
extends: ["eslint:recommended"],
parserOptions: {
ecmaVersion: 5,
sourceType: "script"
sourceType: "script",
},
env: {
browser: true,
commonjs: true
commonjs: true,
},
rules: Object.assign({}, baseRules, {
// Disable all rules about ES6
Expand Down Expand Up @@ -47,6 +47,6 @@ module.exports = {
"sort-imports": "off",
"symbol-description": "off",
"template-curly-spacing": "off",
"yield-star-spacing": "off"
})
"yield-star-spacing": "off",
}),
};
8 changes: 4 additions & 4 deletions lib/flowtype.js
Expand Up @@ -15,8 +15,8 @@ module.exports = {
"error",
{
allowShortCircuit: true,
allowTernary: true
}
allowTernary: true,
},
],
"flowtype/object-type-delimiter": ["error", "comma"],
// flowtype/space-after-type-colon
Expand All @@ -29,7 +29,7 @@ module.exports = {
// Warn
// =======
// flowtype/define-flow-type
"flowtype/semi": "warn"
"flowtype/semi": "warn",
// flowtype/use-flow-type

// =======
Expand All @@ -44,5 +44,5 @@ module.exports = {
// flowtype/require-valid-file-annotation
// flowtype/require-variable-type
// flowtype/sort-keys
}
},
};
4 changes: 2 additions & 2 deletions lib/kintone.js
@@ -1,5 +1,5 @@
module.exports = {
rules: {
strict: ["error", "function"]
}
strict: ["error", "function"],
},
};
4 changes: 2 additions & 2 deletions lib/node-typescript.js
@@ -1,5 +1,5 @@
module.exports = {
rules: {
"node/no-unsupported-features/es-syntax": "off"
}
"node/no-unsupported-features/es-syntax": "off",
},
};
10 changes: 5 additions & 5 deletions lib/node.js
Expand Up @@ -3,13 +3,13 @@ module.exports = {
settings: {
node: {
// https://github.com/mysticatea/eslint-plugin-node/blob/master/docs/rules/no-missing-import.md#tryextensions
tryExtensions: [".js", ".json", ".node", ".ts", ".jsx", ".tsx"]
}
tryExtensions: [".js", ".json", ".node", ".ts", ".jsx", ".tsx"],
},
},
rules: {
"no-console": "off"
"no-console": "off",
},
parserOptions: {
ecmaVersion: 2020
}
ecmaVersion: 2020,
},
};
2 changes: 1 addition & 1 deletion lib/prettier-flowtype.js
@@ -1,3 +1,3 @@
module.exports = {
extends: ["prettier/flowtype"]
extends: ["prettier/flowtype"],
};
2 changes: 1 addition & 1 deletion lib/prettier-react.js
@@ -1,3 +1,3 @@
module.exports = {
extends: ["prettier/react"]
extends: ["prettier/react"],
};
2 changes: 1 addition & 1 deletion lib/prettier-typescript.js
@@ -1,3 +1,3 @@
module.exports = {
extends: ["prettier/@typescript-eslint"]
extends: ["prettier/@typescript-eslint"],
};
2 changes: 1 addition & 1 deletion lib/prettier.js
@@ -1,3 +1,3 @@
module.exports = {
extends: ["plugin:prettier/recommended"]
extends: ["plugin:prettier/recommended"],
};
4 changes: 2 additions & 2 deletions lib/react-typescript.js
@@ -1,6 +1,6 @@
module.exports = {
rules: {
"react/jsx-filename-extension": ["error", { extensions: [".tsx"] }],
"react/prop-types": ["off", {}]
}
"react/prop-types": ["off", {}],
},
};
26 changes: 13 additions & 13 deletions lib/react.js
Expand Up @@ -3,13 +3,13 @@ module.exports = {
extends: ["plugin:react/recommended"],
parserOptions: {
ecmaFeatures: {
jsx: true
}
jsx: true,
},
},
settings: {
react: {
version: "detect"
}
version: "detect",
},
},
rules: {
// =======
Expand Down Expand Up @@ -40,7 +40,7 @@ module.exports = {
"react/prefer-es6-class": "error",
"react/prefer-stateless-function": [
"error",
{ ignorePureComponents: true }
{ ignorePureComponents: true },
],
// react/prop-types too strict?
// react/react-in-jsx-scope
Expand Down Expand Up @@ -70,9 +70,9 @@ module.exports = {
"static-methods",
"lifecycle",
"everything-else",
"render"
]
}
"render",
],
},
],

"react/jsx-boolean-value": "warn",
Expand All @@ -87,7 +87,7 @@ module.exports = {
"react/jsx-no-bind": ["warn", { allowArrowFunctions: true }],
"react/jsx-curly-brace-presence": [
"warn",
{ props: "never", children: "never" }
{ props: "never", children: "never" },
],
"react/jsx-pascal-case": ["warn", { allowAllCaps: true }],
"react/jsx-props-no-multi-spaces": "warn",
Expand All @@ -96,8 +96,8 @@ module.exports = {
{
closingSlash: "never",
beforeSelfClosing: "always",
afterOpening: "never"
}
afterOpening: "never",
},
],
"react/jsx-wrap-multilines": "warn",

Expand Down Expand Up @@ -175,6 +175,6 @@ module.exports = {
"jsx-a11y/role-has-required-aria-props": "warn",
"jsx-a11y/role-supports-aria-props": "warn",
"jsx-a11y/scope": "warn",
"jsx-a11y/tabindex-no-positive": "warn"
}
"jsx-a11y/tabindex-no-positive": "warn",
},
};
6 changes: 3 additions & 3 deletions lib/typescript.js
Expand Up @@ -3,7 +3,7 @@ module.exports = {
plugins: ["@typescript-eslint"],
extends: [
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended"
"plugin:@typescript-eslint/recommended",
],
// It's 5〜10x slower with the project setting.
// So We disable it until the issue has been fixed
Expand Down Expand Up @@ -37,11 +37,11 @@ module.exports = {
"@typescript-eslint/no-use-before-define": "off",
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/prefer-interface": "off",
"@typescript-eslint/prefer-namespace-keyword": "off"
"@typescript-eslint/prefer-namespace-keyword": "off",

// These rules are required type information,
// which means these can be checked without parserOptions.project
// "@typescript-eslint/no-for-in-array": "error",
// "@typescript-eslint/no-unnecessary-type-assertion": "warn",
}
},
};
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.