Skip to content

Commit

Permalink
chore: drop prettier eslint integrations
Browse files Browse the repository at this point in the history
  • Loading branch information
VdustR committed May 1, 2024
1 parent 173ff20 commit 976eb40
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 187 deletions.
1 change: 0 additions & 1 deletion .npmrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@

public-hoist-pattern[]=@mui/utils
public-hoist-pattern[]=@eslint/eslintrc
21 changes: 1 addition & 20 deletions eslint.config.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
import antfu from "@antfu/eslint-config";
import { FlatCompat } from "@eslint/eslintrc";
import * as mdx from "eslint-plugin-mdx";
import simpleImportSort from "eslint-plugin-simple-import-sort";
import tsEslint from "typescript-eslint";

const compat = new FlatCompat();

export default antfu(
{
Expand All @@ -14,22 +10,7 @@ export default antfu(
yaml: false,
toml: false,
markdown: false,
},
...compat.config({
extends: ["plugin:prettier/recommended"],
rules: {
/**
* Inherit strict TypeScript rules from `typescript-eslint`.
*/
...Object.fromEntries(
tsEslint.configs.strict.flatMap((config) => {
if (!config.rules) return [];
return Object.entries(config.rules).map(([rule, value]) => {
const tsRule = rule.replace(/^@typescript-eslint\//, "ts/");
return [tsRule, value];
});
}),
),
/**
* This rule does not integrate well with JSDoc `@link` tags. It's advised
* to verify its behavior with TypeScript instead.
Expand All @@ -43,7 +24,7 @@ export default antfu(
"sort-imports": "off",
"import/order": "off",
},
}),
},
{
files: ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx", "**/*.mdx"],
plugins: {
Expand Down
4 changes: 0 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@
"@repo/utils": "workspace:*",
"@total-typescript/ts-reset": "^0.5.1",
"@types/eslint": "^8.56.10",
"@types/eslint__eslintrc": "^2.1.1",
"@types/lint-staged": "^13.3.0",
"@types/react": "^18.3.1",
"@types/react-dom": "^18.3.0",
Expand All @@ -45,9 +44,7 @@
"commitizen": "^4.3.0",
"cspell": "^8.7.0",
"eslint": "npm:eslint-ts-patch@8.57.0-0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-mdx": "^3.1.5",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-react": "^7.34.1",
"eslint-plugin-react-hooks": "^4.6.2",
"eslint-plugin-react-refresh": "^0.4.6",
Expand All @@ -65,7 +62,6 @@
"stylelint-prettier": "^5.0.0",
"tsx": "^4.8.1",
"typescript": "^5.4.5",
"typescript-eslint": "^7.8.0",
"vite": "^5.2.10"
},
"packageManager": "pnpm@9.0.6+sha256.0624e30eff866cdeb363b15061bdb7fd9425b17bc1bb42c22f5f4efdea21f6b3",
Expand Down
Loading

0 comments on commit 976eb40

Please sign in to comment.