Fized typescript error that wasnt letting me compile, the javascript would still run and so the end result worked but the typescript compile would fail every time. I had to cast the function with <HTMLScriptElement[]><any> to get it to work. I think typescript is kinda dumb considering javascript is meant to be loosely typed and just work, after all it is just web development. Also considering the fact that I dont really see typescript used if at all...just my 2 cents.