eslint-plugin-smells is an ESLint plugin that provides rules to detect code smells in JavaScript. Version 1.0.1 is the latest release. The plugin includes rules such as no-switch, no-complex-switch-case, no-setinterval, no-this-assign, no-complex-string-concat, and no-complex-chaining. It helps enforce cleaner coding practices by flagging common anti-patterns. The project is maintained but has not seen recent updates. It requires ESLint as a peer dependency and is used as an ESLint plugin via the plugins configuration.
npm install eslint-plugin-smellsVerified import paths — ran on the pinned version, not inferred.
Minimal ESLint configuration to enable all code smell rules from eslint-plugin-smells.
Use 'smells/no-switch' instead of 'no-switch'.
Install and configure via .eslintrc plugins array.
Consider alternative plugins like eslint-plugin-sonarjs for more active development.
Run `npm install eslint-plugin-smells --save-dev` and verify package is in node_modules.
Set severity to 1 (warning) or 2 (error), not true.
Add 'smells' to plugins in .eslintrc and ensure rule name is exactly 'smells/no-switch'.