# TS2369: A parameter property is only allowed in a constructor implementation.

> A parameter property (`public x` in a parameter list) is used outside a constructor body. Move it to the constructor, or remove the modifier.

## What it means

Modifiers such as `public`, `private` and `readonly` on parameters declare class
properties, and only work on a constructor implementation. On methods, functions,
constructor overloads or declarations without a body they are reported.

## Example

```ts
export class User {
  greet(private name: string) {
    return name;
  }
}
```

## How to fix

- Remove the modifier, or move the parameter to the constructor.

Source: https://ts-r.dev/errors/TS2369/
