Registry /
testing / eslint-plugin-redundant-undefined
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslnode 18–226 runs
build_error
glibcnode 18–226 runs
build_error
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
redundant-undefined
✓ // In .eslintrc: { "plugins": ["redundant-undefined"], "rules": { "redundant-undefined/redundant-undefined": "error" } }
✗ require('eslint-plugin-redundant-undefined') or import syntax in config is not supported
Plugin is added via plugins array in ESLint config; rules are prefixed with 'redundant-undefined/'
default rule
✓ rules: { "redundant-undefined/redundant-undefined": "error" }
✗ Setting 'redundant-undefined' as a top-level rule like 'redundant-undefined': 'error' (missing slash) or using wrong rule name
Rule name is 'redundant-undefined/redundant-undefined' – the plugin name and rule name are identical but separated by a slash
Minimal ESLint config to enable the plugin and rule, plus an example of incorrect code.
// .eslintrc.json
{
"parser": "@typescript-eslint/parser",
"plugins": ["redundant-undefined"],
"rules": {
"redundant-undefined/redundant-undefined": "error"
}
}
// Install
// npm i eslint-plugin-redundant-undefined @typescript-eslint/parser eslint --save-dev
// Example code that will be flagged:
// function f(s?: string | undefined): void {}
Errors
Common errors & fixes
Error: Failed to load plugin 'redundant-undefined': Cannot find module 'eslint-plugin-redundant-undefined'
Plugin not installed or missing from node_modules.
fixRun `npm install eslint-plugin-redundant-undefined @typescript-eslint/parser --save-dev`
Parsing error: 'parserOptions.project' has been set for @typescript-eslint/parser. The file does not match your project config: .eslintrc.json
ESLint is trying to parse the config file itself with TypeScript parser.
fixAdd `'ignorePatterns': ['.eslintrc.json']` to your ESLint config or use a .eslintrc.js file.
Error: Rule 'redundant-undefined' (or 'redundant-undefined/redundant-undefined') is not defined
Plugin not listed in 'plugins' array or rule name misspelled.
fixAdd 'redundant-undefined' to plugins and use 'redundant-undefined/redundant-undefined' as rule name.
Audit
Dependencies
@typescript-eslint/parserrequiredPeer dependency required to parse TypeScript syntax
eslintrequiredPeer dependency; plugin is an ESLint rule