# no-useless-constructor

Rule `typescript/no-useless-constructor`. Disallow unnecessary constructors

- Source: typescript
- Technologies: TypeScript
- Kind: style
- Needs type information: no
- Autofix: yes, in at least one linter
- Reach: 52.3M weekly downloads of presets that enable it
- Trend: +26.6% last quarter
- Rank: #244 by reach, #1360 by growth

## Linters

| Linter | Rule name | Recommended | Autofix | Details | Docs |
| --- | --- | --- | --- | --- | --- |
| ESLint | `@typescript-eslint/no-useless-constructor` | no | suggestion | package `@typescript-eslint/eslint-plugin` | [docs](https://typescript-eslint.io/rules/no-useless-constructor) |
| Biome | `complexity/noUselessConstructor` | yes | unsafe | group complexity, since 1.0.0 | [docs](https://biomejs.dev/linter/rules/no-useless-constructor/) |

## Code examples

### Incorrect: the rule reports this

```js
class A {
    constructor (a) {}
}
```

```js
class B extends A {
    constructor (a) {
        super(a);
    }
}
```

```js
class C {
    /**
     * Documented constructor.
     */
    constructor () {}
}
```

### Correct: the rule accepts this

```js
class A {
    constructor (prop) {
        this.prop = prop;
    }
}
```

```js
class B extends A {
    constructor () {
        super(5);
    }
}
```

```ts
class C {
    // Empty constructor with parameter properties are allowed.
    constructor (private prop: number) {}
}
```

Examples from the Biome documentation.

## Enable it

### ESLint: `eslint.config.js`

```js
import tseslint from "typescript-eslint";

export default [
  {
    plugins: { "@typescript-eslint": tseslint.plugin },
    rules: {
      "@typescript-eslint/no-useless-constructor": "error",
    },
  },
];
```

### Biome: `biome.json`

```json
{
  "linter": {
    "rules": {
      "complexity": {
        "noUselessConstructor": "error"
      }
    }
  }
}
```

## Presets that enable it

| Preset | Linter | Package | Rules | Weekly downloads | Trend |
| --- | --- | --- | --- | --- | --- |
| [typescript-eslint strict](https://lintradar.dev/presets/typescript-eslint-strict.md) | ESLint | `@typescript-eslint/eslint-plugin` | 32 | 175.9M | +29.5% |
| [typescript-eslint strict type-checked](https://lintradar.dev/presets/typescript-eslint-strict-type-checked.md) | ESLint | `@typescript-eslint/eslint-plugin` | 75 | 175.9M | +29.5% |
| [Create React App](https://lintradar.dev/presets/react-app.md) | ESLint | `eslint-config-react-app` | 109 | 4.1M | +4.3% |
| [Airbnb TypeScript](https://lintradar.dev/presets/airbnb-typescript.md) | ESLint | `eslint-config-airbnb-typescript` | 19 | 1.8M | +1.2% |
| [Nuxt](https://lintradar.dev/presets/nuxt.md) | ESLint | `@nuxt/eslint-config` | 188 | 1.5M | +72.8% |
| [XO](https://lintradar.dev/presets/xo.md) | ESLint | `eslint-config-xo` | 618 | 413K | −5.0% |
| [neostandard](https://lintradar.dev/presets/neostandard.md) | ESLint | `neostandard` | 95 | 317.6K | +50.2% |
| [eslint-config-love](https://lintradar.dev/presets/love.md) | ESLint | `eslint-config-love` | 258 | 171.7K | +39.3% |
| [Alloy](https://lintradar.dev/presets/alloy.md) | ESLint | `eslint-config-alloy` | 166 | 31.4K | +32.4% |

## Related rules

- [eslint/no-useless-constructor](https://lintradar.dev/rules/eslint/no-useless-constructor.md): Disallow unnecessary constructors
- [typescript/require-array-sort-compare](https://lintradar.dev/rules/typescript/require-array-sort-compare.md): Require `Array#sort` and `Array#toSorted` calls to always provide a `compareFunction`
- [typescript/consistent-type-assertions](https://lintradar.dev/rules/typescript/consistent-type-assertions.md): Enforce consistent usage of type assertions
- [typescript/no-unnecessary-parameter-property-assignment](https://lintradar.dev/rules/typescript/no-unnecessary-parameter-property-assignment.md): Disallow unnecessary assignment of constructor property parameter
- [typescript/no-non-null-assertion](https://lintradar.dev/rules/typescript/no-non-null-assertion.md): Disallow non-null assertions using the `!` postfix operator
- [typescript/no-non-null-asserted-nullish-coalescing](https://lintradar.dev/rules/typescript/no-non-null-asserted-nullish-coalescing.md): Disallow non-null assertions in the left operand of a nullish coalescing operator

---

Web page: https://lintradar.dev/rules/typescript/no-useless-constructor. Data from npm and the linters' documentation, collected Dec 4, 2026. Site guide for agents: https://lintradar.dev/llms.txt
