When the nursery/noUnusedImports rule is used in a file where a type is imported, it will detect that import as unused (even though it's actually used). import type NextAuth from 'next-auth/next'; const a: typeof NextAuth = {} Expected result Because the import is actually used, it...
complexity/noUselessLoneBlockStatements style/noArguments a11y/useValidAriaValues suspicious/noDebugger suspicious/noMisleadingInstantiator suspicious/noPrototypeBuiltins suspicious/noGlobalAssign suspicious/noCommentText suspicious/noDuplicateJsxProps suspicious/noThenProperty a11y/noPositiveTabindex correctness/noEmp...
配置rules "no-unused-vars":"off",//or"@typescript-eslint/no-unused-vars":"off","unused-imports/no-unused-imports":"error","unused-imports/no-unused-vars": ["warn", {"vars":"all","varsIgnorePattern":"^_","args":"after-used","argsIgnorePattern":"^_"} ], Prettier 和 ESLint ...
配置rules "no-unused-vars":"off",//or"@typescript-eslint/no-unused-vars":"off","unused-imports/no-unused-imports":"error","unused-imports/no-unused-vars": ["warn", {"vars":"all","varsIgnorePattern":"^_","args":"after-used","argsIgnorePattern":"^_"} ], Prettier 和 ESLint ...
Description Currently, noUnusedImports signals any unused import. This leads to a lot of diagnostics. Instead, we could signal all unused imports within an import statement at once. This will allow addressing #3574 and could mitigate #3383.
no-unused-variable reports All imports are unused. example: ERROR: src/providers/routes/MockRoutesFactory.ts[2, 1]: All imports are unused. Expected behavior No errors should be found for this file. andy-hansoncommentedApr 15, 2017 I can't reproduce this in a sample project. Can you try...
Addunused-importsto the plugins section of youreslint.config.jsconfiguration file. importunusedImportsfrom"eslint-plugin-unused-imports";exportdefault[{plugins:{"unused-imports":unusedImports,},rules:{"no-unused-vars":"off",// or "@typescript-eslint/no-unused-vars": "off","unused-imports/no...
New issue Bug: [@typescript-eslint/no-unused-vars] Error "is defined but never used" for decorator imports on Typescript 4.8 #5866 Closed 4 tasks done bogdanb opened this issue Oct 24, 2022· 5 comments CommentsContributor bogdanb commented Oct 24, 2022 ...
For some reason (now on current master/latest released gitpkg version 0.1.0-dev.5) explicitly turning off @typescript-eslint/no-unused-vars is causing lots of false positives of known-imports/no-unused-vars - looks like it's not recogniz...
Environment data Language Server version: 2023.9.10 (pyright c70adefc) OS and version: Windows 11 Python version (& distribution if applicable, e.g. Anaconda): 3.10.11 Code Snippet Using a pretty minimal repro here, but just this: from t...