Loading
refactor: disallow TS parameter properties
This MR disallows parameter properties in TypeScript. Parameter properties are nice shorthand for small classes like errors. But for any other uses, they bring in inconsistency (some properties are defined in the constructor, and some are defined in the class).
There is also the conflict between TS private keyword and the ES2022 private fields. ES2022 private fields are preferable because the node engine makes them private compared to the TS private keyword, which gets stripped at compile time, and then the fields are public.
The ES2022 private field can't be declared using parameter properties.
The eslint rule description https://typescript-eslint.io/rules/parameter-properties/