error TS2683: ‘this’ implicitly has type ‘any’ because it does not have a type annotation.
Broken Code ❌
Fixed Code ✔️
This bug is also a consequence of TS2680. To fix the bug we have to define the context of our function. It can be done by defining
this as the first parameter in our argument list and giving it a type annotation: