diff --git a/.eslintrc.js b/.eslintrc.js index b66539acec105..692ec549f898d 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -50,6 +50,7 @@ module.exports = { 'posthog', 'simple-import-sort', 'import', + "unused-imports" ], rules: { // PyCharm always adds curly braces, I guess vscode doesn't, PR reviewers often complain they are present on props that don't need them @@ -73,6 +74,7 @@ module.exports = { html: true, }, ], + "unused-imports/no-unused-imports": "error", 'no-unused-vars': 'off', '@typescript-eslint/no-unused-vars': [ 'error', diff --git a/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown--dark.png b/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown--dark.png index 729faab2b5537..6fd194e19ee1c 100644 Binary files a/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown--dark.png and b/frontend/__snapshots__/scenes-app-insights--funnel-top-to-bottom-breakdown--dark.png differ diff --git a/package.json b/package.json index 4a26212416736..8842797cedd54 100644 --- a/package.json +++ b/package.json @@ -260,6 +260,7 @@ "eslint-plugin-react": "^7.33.2", "eslint-plugin-simple-import-sort": "^10.0.0", "eslint-plugin-storybook": "^0.6.15", + "eslint-plugin-unused-imports": "^3.1.0", "file-loader": "^6.1.0", "givens": "^1.3.6", "history": "^5.0.1", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index cdb85637f8a31..2a8600162a102 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -593,6 +593,9 @@ devDependencies: eslint-plugin-storybook: specifier: ^0.6.15 version: 0.6.15(eslint@8.52.0)(typescript@4.9.5) + eslint-plugin-unused-imports: + specifier: ^3.1.0 + version: 3.1.0(@typescript-eslint/eslint-plugin@7.1.1)(eslint@8.52.0) file-loader: specifier: ^6.1.0 version: 6.2.0(webpack@5.88.2) @@ -12100,6 +12103,26 @@ packages: - typescript dev: true + /eslint-plugin-unused-imports@3.1.0(@typescript-eslint/eslint-plugin@7.1.1)(eslint@8.52.0): + resolution: {integrity: sha512-9l1YFCzXKkw1qtAru1RWUtG2EVDZY0a0eChKXcL+EZ5jitG7qxdctu4RnvhOJHv4xfmUf7h+JJPINlVpGhZMrw==} + engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + peerDependencies: + '@typescript-eslint/eslint-plugin': 6 - 7 + eslint: '8' + peerDependenciesMeta: + '@typescript-eslint/eslint-plugin': + optional: true + dependencies: + '@typescript-eslint/eslint-plugin': 7.1.1(@typescript-eslint/parser@7.1.1)(eslint@8.52.0)(typescript@4.9.5) + eslint: 8.52.0 + eslint-rule-composer: 0.3.0 + dev: true + + /eslint-rule-composer@0.3.0: + resolution: {integrity: sha512-bt+Sh8CtDmn2OajxvNO+BX7Wn4CIWMpTRm3MaiKPCQcnnlm0CS2mhui6QaoeQugs+3Kj2ESKEEGJUdVafwhiCg==} + engines: {node: '>=4.0.0'} + dev: true + /eslint-scope@5.1.1: resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==} engines: {node: '>=8.0.0'}