Skip to content

Commit

Permalink
Fix eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
tajo committed May 30, 2024
1 parent 04ef1b3 commit d6848c7
Show file tree
Hide file tree
Showing 11 changed files with 769 additions and 709 deletions.
21 changes: 0 additions & 21 deletions .eslintrc.json

This file was deleted.

30 changes: 30 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import react from "eslint-plugin-react/configs/recommended.js";
import prettier from "eslint-plugin-prettier/recommended";
import eslint from "@eslint/js";
import tseslint from "typescript-eslint";

export default tseslint.config(
eslint.configs.recommended,
...tseslint.configs.recommended,
prettier,
react,
{
files: ["**/*.ts", "**/*.tsx"],
rules: {
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/ban-types": "off",
"@typescript-eslint/ban-ts-comment": "off",
"@typescript-eslint/explicit-module-boundary-types": "off",
"react/prop-types": "off",
"react/react-in-jsx-scope": "off",
"no-useless-escape": "off",
"no-empty": "off",
"no-global-assign": "off",
},
settings: {
react: {
version: "detect",
},
},
},
);
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,20 @@
"@changesets/cli": "^2.27.5",
"@commitlint/cli": "^19.3.0",
"@commitlint/config-conventional": "^19.2.2",
"@eslint/js": "^9.3.0",
"@playwright/test": "^1.44.1",
"@types/eslint__js": "^8.42.3",
"@types/react": "^18.3.3",
"@types/react-dom": "^18.3.0",
"@typescript-eslint/eslint-plugin": "^7.11.0",
"@typescript-eslint/parser": "^7.11.0",
"eslint": "^9.3.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-react": "^7.34.2",
"husky": "^9.0.11",
"lint-staged": "^15.2.5",
"prettier": "^3.2.5",
"turbo": "^1.13.3",
"typescript": "^5.4.5"
"typescript": "^5.4.5",
"typescript-eslint": "^7.11.0"
},
"engines": {
"node": ">=20.9.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/ladle/lib/app/src/args-provider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ const ArgsProvider = ({
argTypes &&
argTypes[key] &&
argTypes[key].mapping &&
argTypes[key].mapping.hasOwnProperty(value)
Object.prototype.hasOwnProperty.call(argTypes[key].mapping, value)
) {
return argTypes[key].mapping[value];
}
Expand Down
Loading

0 comments on commit d6848c7

Please sign in to comment.