diff --git a/README.md b/README.md index 5057ac3..b4cf50f 100644 --- a/README.md +++ b/README.md @@ -66,19 +66,19 @@ gh get timobechtel/style templates/react/.oxlintrc.jsonc
Migrating to Oxlint? - `File '@timobechtel/style/tsconfig/core' not found.` - When migrating from ESLint to Oxlint, you might need to update the `tsconfig.json` file: +When migrating from ESLint to Oxlint, you might need to update the `tsconfig.json` file: - ```diff - - "extends": ["@timobechtel/style/tsconfig/core"] - + "extends": ["@timobechtel/style/tsconfig/core.json"] - ``` +```diff +- "extends": ["@timobechtel/style/tsconfig/core"] ++ "extends": ["@timobechtel/style/tsconfig/core.json"] +``` - ```diff - - "extends": ["@timobechtel/style/tsconfig/react"] - + "extends": ["@timobechtel/style/tsconfig/react.json"] - ``` +```diff +- "extends": ["@timobechtel/style/tsconfig/react"] ++ "extends": ["@timobechtel/style/tsconfig/react.json"] +``` - > tsgolint requires a file extension to resolve the config file. +> tsgolint requires a file extension to resolve the config file.
diff --git a/bun.lockb b/bun.lockb index f76f65b..72186e8 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/oxlint/core.jsonc b/oxlint/core.jsonc index 80b58eb..c6a5528 100644 --- a/oxlint/core.jsonc +++ b/oxlint/core.jsonc @@ -6,6 +6,9 @@ "oxc", "import" ], + "jsPlugins": [ + "oxlint-plugin-complexity" + ], "categories": { "correctness": "error", "suspicious": "error", @@ -187,6 +190,14 @@ // report duplicate code in branches "oxc/branches-sharing-code": "warn", + "complexity/complexity": [ + "warn", + { + "cyclomatic": 20, + "cognitive": 15, + "minLines": 15 + } + ], // prevent mixing value and non-value returns in functions "typescript/consistent-return": "warn", "typescript/no-unnecessary-qualifier": "warn", diff --git a/package.json b/package.json index 1c394e2..c6bcf2d 100644 --- a/package.json +++ b/package.json @@ -45,6 +45,8 @@ "eslint-plugin-unicorn": "^63.0.0", "globals": "^17.3.0", "oxlint-tsgolint": "^0.16.0", - "typescript-eslint": "^8.56.0" + "typescript-eslint": "^8.56.0", + "@oxlint/plugins": "^1.63.0", + "oxlint-plugin-complexity": "^2.1.2" } }