From 69873ad9157bf0b4fb59bf0a3e1875e3e3526b78 Mon Sep 17 00:00:00 2001 From: James Ives <iam@jamesiv.es> Date: Wed, 17 Apr 2024 09:18:41 -0400 Subject: [PATCH] Update eslint.config.mjs --- eslint.config.mjs | 88 +++++++++++++++++++++++------------------------ 1 file changed, 44 insertions(+), 44 deletions(-) diff --git a/eslint.config.mjs b/eslint.config.mjs index 669a45db8..94a01764c 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -1,7 +1,7 @@ -import eslint from '@eslint/js'; -import tseslint from 'typescript-eslint'; -import eslintConfigPrettier from "eslint-config-prettier"; -import jest from "eslint-plugin-jest"; +import eslint from '@eslint/js' +import tseslint from 'typescript-eslint' +import eslintConfigPrettier from 'eslint-config-prettier' +import jest from 'eslint-plugin-jest' export default tseslint.config( eslintConfigPrettier, @@ -10,63 +10,63 @@ export default tseslint.config( ...tseslint.configs.recommended, { languageOptions: { - globals: { - process: true, - module: true, - } + globals: { + process: true, + module: true + } }, rules: { - "jest/no-conditional-expect": "off", - "@typescript-eslint/ban-types": [ - "error", + 'jest/no-conditional-expect': 'off', + '@typescript-eslint/ban-types': [ + 'error', { types: { - "Number": { - "message": "Use number instead", - "fixWith": "number" + Number: { + message: 'Use number instead', + fixWith: 'number' }, - "String": { - "message": "Use string instead", - "fixWith": "string" + String: { + message: 'Use string instead', + fixWith: 'string' }, - "Boolean": { - "message": "Use boolean instead", - "fixWith": "boolean" + Boolean: { + message: 'Use boolean instead', + fixWith: 'boolean' }, - "Object": { - "message": "Use object instead", - "fixWith": "object" + Object: { + message: 'Use object instead', + fixWith: 'object' }, - "{}": { - "message": "Use object instead", - "fixWith": "object" + '{}': { + message: 'Use object instead', + fixWith: 'object' }, - "Symbol": { - "message": "Use symbol instead", - "fixWith": "symbol" + Symbol: { + message: 'Use symbol instead', + fixWith: 'symbol' } } } ], - "@typescript-eslint/array-type": ["error", {"default": "array"}], - "@typescript-eslint/explicit-module-boundary-types": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/explicit-function-return-type": "error", - "object-shorthand": ["error", "always"], - "prefer-destructuring": [ - "error", + '@typescript-eslint/array-type': ['error', {default: 'array'}], + '@typescript-eslint/explicit-module-boundary-types': 'error', + '@typescript-eslint/no-explicit-any': 'error', + '@typescript-eslint/no-unused-vars': 'error', + '@typescript-eslint/explicit-function-return-type': 'error', + 'object-shorthand': ['error', 'always'], + 'prefer-destructuring': [ + 'error', { - "array": false, - "object": true + array: false, + object: true }, { - "enforceForRenamedProperties": false + enforceForRenamedProperties: false } ], - "no-console": ["error", {"allow": ["warn", "error"]}], - "no-alert": "error", - "no-debugger": "error" + 'no-console': ['error', {allow: ['warn', 'error']}], + 'no-alert': 'error', + 'no-debugger': 'error' } } -); \ No newline at end of file +)