Skip to content

Commit

Permalink
update eslint to latest
Browse files Browse the repository at this point in the history
  • Loading branch information
lastlink committed Jul 5, 2024
1 parent ca4d1cd commit 9b2c04f
Show file tree
Hide file tree
Showing 7 changed files with 732 additions and 966 deletions.
1 change: 1 addition & 0 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,6 @@ jobs:
with:
node-version: current
- run: npm ci
- run: npm run lint
- run: npm test
- run: npm run build:client:all
89 changes: 38 additions & 51 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,53 +1,40 @@
{
"parser": "@typescript-eslint/parser",
"extends": [
"plugin:@typescript-eslint/recommended"
],
"parserOptions": {
"ecmaVersion": 2018,
"allowImportExportEverywhere": true,
"sourceType": "module"
import globals from "globals";
import pluginJs from "@eslint/js";
import tseslint from "typescript-eslint";

export default [
pluginJs.configs.recommended,
...tseslint.configs.recommended,
{
files: ["**/*.{js,mjs,cjs,ts}"],
rules: {
semi: ["error", "always"],
quotes: ["error", "double"],
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/camelcase": "off",
"@typescript-eslint/no-unsafe-function-type": "off",
"@typescript-eslint/no-explicit-any": "off",
"no-useless-escape": "off",
"no-multiple-empty-lines": "error",
"no-use-before-define": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/no-use-before-define": "off",
"@typescript-eslint/no-inferrable-types": [
"warn",
{
ignoreParameters: true,
},
],
"@typescript-eslint/no-unused-vars": "warn",
"@typescript-eslint/class-name-casing": "off",
},
"rules": {
"semi": [
"error",
"always"
],
"quotes": [
"error",
"double"
],
"@typescript-eslint/explicit-function-return-type": "off",
"@typescript-eslint/camelcase": "off",
"@typescript-eslint/no-explicit-any": "off",
"no-multiple-empty-lines": "error",
"no-use-before-define": "off",
"@typescript-eslint/no-non-null-assertion": "off",
"@typescript-eslint/no-use-before-define": "off",
"@typescript-eslint/no-inferrable-types": [
"warn",
{
"ignoreParameters": true
}
],
"@typescript-eslint/no-unused-vars": "warn",
"@typescript-eslint/class-name-casing": "off"
ignores: ["lib/*", "deps/*", "dist/*", "archived"],
},
{
files: ["**/__tests__/*.{j,t}s?(x)", "**/tests/**/*.spec.{j,t}s?(x)"],
env: {
jest: true,
},
"ignorePatterns": [
"lib/*",
"deps/*",
"dist/*",
"archived"
],
"overrides": [
{
"files": [
"**/__tests__/*.{j,t}s?(x)",
"**/tests/**/*.spec.{j,t}s?(x)"
],
"env": {
"jest": true
}
}
]
}
},
{ languageOptions: { globals: globals.browser } }
];
Loading

0 comments on commit 9b2c04f

Please sign in to comment.