From cb1348c9f5727eaecfc805ed8fb4b05e2cddc2a2 Mon Sep 17 00:00:00 2001 From: hieu-w Date: Wed, 15 Jan 2025 00:17:23 +0700 Subject: [PATCH] Eslint 9 flat config migration --- .eslintignore | 25 ------------------------- .eslintrc.js | 16 ---------------- eslint.config.mjs | 3 +++ 3 files changed, 3 insertions(+), 41 deletions(-) delete mode 100644 .eslintignore delete mode 100644 .eslintrc.js create mode 100644 eslint.config.mjs diff --git a/.eslintignore b/.eslintignore deleted file mode 100644 index b7795bf2..00000000 --- a/.eslintignore +++ /dev/null @@ -1,25 +0,0 @@ -# See https://help.github.com/ignore-files/ for more about ignoring files. - -# dependencies -/node_modules - -# testing -/coverage - -#production -/build - -# misc -.DS_Store -.env.local -.env.development.local -.env.test.local -.env.production.local - -npm-debug.log* -yarn-debug.log* -yarn-error.log* -examples/ -types/ -dist/ -**/sw.js \ No newline at end of file diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index f93acc9a..00000000 --- a/.eslintrc.js +++ /dev/null @@ -1,16 +0,0 @@ -require("@rushstack/eslint-patch/modern-module-resolution"); - -module.exports = { - root: true, - extends: ["@toruslabs/eslint-config-typescript"], - parser: "@typescript-eslint/parser", - ignorePatterns: ["*.config.js", ".eslintrc.js"], - parserOptions: { - sourceType: "module", - ecmaVersion: 2022, - project: "./tsconfig.json", - }, - rules: { - camelcase: 0, - }, -}; diff --git a/eslint.config.mjs b/eslint.config.mjs new file mode 100644 index 00000000..993f6a48 --- /dev/null +++ b/eslint.config.mjs @@ -0,0 +1,3 @@ +import toruslabsTypescript from "@toruslabs/eslint-config-typescript"; + +export default [...toruslabsTypescript];