From 4097b5bd7bdbe8f80ff74ada479459e1cf37ef44 Mon Sep 17 00:00:00 2001 From: IRBorisov <8611739+IRBorisov@users.noreply.github.com> Date: Sun, 28 Apr 2024 22:19:10 +0300 Subject: [PATCH] Fix eslint setup --- .eslintrc.cjs | 5 +++++ package.json | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.eslintrc.cjs b/.eslintrc.cjs index 6566c5a8..efd9c8e3 100644 --- a/.eslintrc.cjs +++ b/.eslintrc.cjs @@ -12,6 +12,11 @@ module.exports = { 'ecmaVersion': 12, 'sourceType': 'module' }, + 'settings': { + 'react': { + 'version': 'detect' + } + }, 'plugins': ['react', '@typescript-eslint'], 'rules': { 'no-prototype-builtins': 'off', diff --git a/package.json b/package.json index 5e0788ec..819157e5 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "test": "vitest --passWithNoTests", "test:coverage": "vitest run --coverage --passWithNoTests", "prettier": "prettier --loglevel warn --write 'src/**/*.{ts,tsx,js,jsx}'", - "lint": "eslint --ext js,ts,tsx", + "lint": "eslint --ext js,ts,tsx src", "lint:fix": "eslint --ext js,ts,tsx --fix src", "start": "storybook dev -p 9009", "build-storybook": "storybook build",