diff --git a/eslint.config.mjs b/eslint.config.mjs index b0e98aa..05ee29e 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -1,40 +1,44 @@ -import { FlatCompat } from "@eslint/eslintrc"; -import js from "@eslint/js"; -import typescriptEslint from "@typescript-eslint/eslint-plugin"; -import tsParser from "@typescript-eslint/parser"; -import globals from "globals"; -import path from "node:path"; -import { fileURLToPath } from "node:url"; +import { FlatCompat } from '@eslint/eslintrc' +import js from '@eslint/js' +import typescriptEslint from '@typescript-eslint/eslint-plugin' +import tsParser from '@typescript-eslint/parser' +import globals from 'globals' +import path from 'node:path' +import { fileURLToPath } from 'node:url' -const __filename = fileURLToPath(import.meta.url); -const __dirname = path.dirname(__filename); +const __filename = fileURLToPath(import.meta.url) +const __dirname = path.dirname(__filename) const compat = new FlatCompat({ - allConfig: js.configs.all, - baseDirectory: __dirname, - recommendedConfig: js.configs.recommended -}); + allConfig: js.configs.all, + baseDirectory: __dirname, + recommendedConfig: js.configs.recommended, +}) -export default [{ - ignores: ["**/lib/"], -}, ...compat.extends( - "eslint:recommended", - "plugin:@typescript-eslint/recommended", - "plugin:sort/recommended", -), { +export default [ + { + ignores: ['**/lib/'], + }, + ...compat.extends( + 'eslint:recommended', + 'plugin:@typescript-eslint/recommended', + 'plugin:sort/recommended', + ), + { languageOptions: { - globals: { - ...globals.jest, - ...globals.node, - }, + globals: { + ...globals.jest, + ...globals.node, + }, - parser: tsParser, + parser: tsParser, }, plugins: { - "@typescript-eslint": typescriptEslint, + '@typescript-eslint': typescriptEslint, }, rules: { - "@typescript-eslint/no-non-null-assertion": "off", + '@typescript-eslint/no-non-null-assertion': 'off', }, -}]; + }, +] diff --git a/packages/eslint-config-widen/src/react.ts b/packages/eslint-config-widen/src/react.ts index cc03dd0..152e8b8 100644 --- a/packages/eslint-config-widen/src/react.ts +++ b/packages/eslint-config-widen/src/react.ts @@ -40,7 +40,7 @@ export = { 'react/jsx-curly-brace-presence': ['warn', 'never'], 'react/jsx-first-prop-new-line': ['error', 'multiline'], 'react/jsx-no-duplicate-props': 'error', - 'react/jsx-no-useless-fragment' : 'error', + 'react/jsx-no-useless-fragment': 'error', 'react/jsx-sort-props': [ 'error', { diff --git a/packages/eslint-plugin-widen/README.md b/packages/eslint-plugin-widen/README.md index 70be903..2d81e7a 100644 --- a/packages/eslint-plugin-widen/README.md +++ b/packages/eslint-plugin-widen/README.md @@ -27,7 +27,8 @@ Add the following to your `.eslintrc` file. ## List of Supported Rules ✔: Enabled in the `recommended` configuration.\ -🔧: Fixable with [`eslint --fix`](https://eslint.org/docs/user-guide/command-line-interface#fixing-problems). +🔧: Fixable with +[`eslint --fix`](https://eslint.org/docs/user-guide/command-line-interface#fixing-problems). | ✔ | 🔧 | Rule | Description | | :-: | :-: | -------------------------------------------- | ------------------------------------------------------------------------------------------- |