no-unsafe-declaration-merging
Configuration
rslint.config.ts
Rule Details
Disallows unsafe declaration merging between a class and an interface. TypeScript allows a class and an interface that share the same name in the same scope to merge into a single declaration. Properties declared on the interface are added to the resulting type without forcing the class to actually initialize them, so accessing such a property on a class instance type-checks but throws Cannot read properties of undefined at runtime.
Examples of incorrect code for this rule:
Examples of correct code for this rule: