TS2365
Operator '+' cannot be applied to types 'number' and 'object'.
Broken Code ❌
export function add(a: number, b: object): number {
return a + b;
}Fixed Code ✔️
You can use the + operator only with equivalent data types (strings + strings or numbers + numbers):
export function add(a: number, b: number): number {
return a + b;
}