Typescript Typeerror Is Not A Constructor