Can anyone explain why I am receiving this error in TypeScript 3.9.2:
'new' expression, whose target lacks a construct signature, implicitly has an 'any' type.
The code triggering the error is shown below:
const Module = function(){
function sayHello(){
console.log('Hello');
}
return {
sayHello: sayHello
}
};
let module: any = new Module();