diff --git a/web/.eslintrc.js b/web/.eslintrc.js index 6686baf50..1bd05c74f 100644 --- a/web/.eslintrc.js +++ b/web/.eslintrc.js @@ -9,8 +9,10 @@ module.exports = { typescript: {}, }, }, + plugins: ["@limegrass/import-alias"], extends: ["react-app", "plugin:import/errors", "plugin:import/warnings", "plugin:prettier/recommended", "prettier"], rules: { + "@limegrass/import-alias/import-alias": "error", "import/order": [ "error", { diff --git a/web/package.json b/web/package.json index 84806709d..e393a8e93 100644 --- a/web/package.json +++ b/web/package.json @@ -145,6 +145,7 @@ "devDependencies": { "@commitlint/cli": "17.3.0", "@commitlint/config-conventional": "17.3.0", + "@limegrass/eslint-plugin-import-alias": "1.0.6", "@testing-library/jest-dom": "5.16.5", "@testing-library/react": "13.4.0", "@types/jest": "29.2.3", diff --git a/web/pnpm-lock.yaml b/web/pnpm-lock.yaml index ce1a8ae16..0716e12d6 100644 --- a/web/pnpm-lock.yaml +++ b/web/pnpm-lock.yaml @@ -10,6 +10,7 @@ specifiers: '@fortawesome/free-regular-svg-icons': 6.2.1 '@fortawesome/free-solid-svg-icons': 6.2.1 '@fortawesome/react-fontawesome': 0.2.0 + '@limegrass/eslint-plugin-import-alias': 1.0.6 '@mui/icons-material': 5.10.15 '@mui/material': 5.10.15 '@mui/styles': 5.10.15 @@ -95,6 +96,7 @@ dependencies: devDependencies: '@commitlint/cli': 17.3.0 '@commitlint/config-conventional': 17.3.0 + '@limegrass/eslint-plugin-import-alias': 1.0.6_eslint@8.28.0 '@testing-library/jest-dom': 5.16.5 '@testing-library/react': 13.4.0_biqbaboplfbrettd7655fr4n2y '@types/jest': 29.2.3 @@ -2853,6 +2855,19 @@ packages: '@jridgewell/sourcemap-codec': 1.4.14 dev: true + /@limegrass/eslint-plugin-import-alias/1.0.6_eslint@8.28.0: + resolution: {integrity: sha512-BtPmdHbL4NmkVh2wMnOboyOCrdLOpBqwwtBIsB0/giTiALw/UTHD9TyH4vVnbDOuWPZQgE6kKloJ9G77FApt7w==} + peerDependencies: + eslint: ^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8 + dependencies: + eslint: 8.28.0 + find-up: 5.0.0 + fs-extra: 10.1.0 + micromatch: 4.0.5 + slash: 3.0.0 + tsconfig-paths: 3.14.1 + dev: true + /@mui/base/5.0.0-alpha.107_2zx2umvpluuhvlq44va5bta2da: resolution: {integrity: sha512-HX/BD8CSe+Y/dpbZ5aKJScJhKQ/Hw6du2yd68Upv2cO67bwixyZ64h3aNcdDu7RQzI7nrZQm0JykffP1Orgq0g==} engines: {node: '>=12.0.0'}