Skip to main content
ESLint Interlace
Plugin: react-featuresRules

no-is-prefix-prop

Boolean props must not be prefixed with `is` (R8)

Part of: componentApi preset (opt-in — not in recommended)

Boolean props default to false and their name should describe the true state directly. The is prefix is redundant noise: looped reads naturally, isLooped does not. This follows the same convention flagged by MUI's component API guidelines.

Why This Matters

IssueImpactSolution
Redundant prefixisOpen, isDisabled are wordier than necessaryRename to open, disabled
InconsistencyHTML uses disabled, checked, open — no is prefixMatch the platform convention

Examples

Incorrect

interface ButtonProps {
  isDisabled: boolean;  // ❌ R8 — rename to `disabled`
  isLoading: boolean;   // ❌ R8 — rename to `loading`
}

Correct

interface ButtonProps {
  disabled?: boolean;
  loading?: boolean;
}

Suggestions

This rule provides a rename suggestion (not an auto-fix) because renaming the prop has consumer-side blast radius — call sites must be updated manually.

Configuration

// eslint.config.mjs
export default [
  {
    rules: {
      "react-features/no-is-prefix-prop": "error",
    },
  },
];

This rule is part of eslint-plugin-react-features.