The problem is that ISumanInputs does not include one or more properties that you include in your call, or that you have incorrectly executed the ISumanInputs interface.
In the case of additional property, you should get one "additional" error:
An object literal can specify only known properties, and 'anExtraProp' does not exist in the type 'ISumanInputs'
If there is no property, you will get another "additional" error:
Missing property timestamp 'type' {fileName: string; networkLog: string; outputPath: string; } ".
Interestingly, if you move the argument definition outside the line, the extra property case will no longer fail:
const data = { fileName: "abc", networkLog: "", outputPath: "", timestamp: "", anExtraProperty: true }; new Suman(data);
source share