RedditPP Mascot

RedditPP

r/typescript • … • u/TOO_MUCH_MOISTURE

Examples of bad typescript code ?

Hello all. I’m hoping the hive mind of fellow nerds can help me with the above.

I have a technical interview Friday, in which I will be tasked to give a code review on a typescript file. That’s all I know about it. I thought it would be easier to find some examples or a medium article with some “bad code” so I could practice picking through it but it’s been harder than I thought.

I’ve given code reviews in my current job with the Co-op students on my team, but I also feel like I’m not the best at a code review to start with. To add to the pressure, I haven’t used Typescript a ton - our codebase is all Vue3 / Node.js.

I’m planning on trying to get as many “low hanging fruit” as I can- such as looking for where code is repetitive, poorly named variables, functions don’t cover a test case, but I’d love to have some examples to work with in Typescript.

Open to any and all suggestions!

Thank you in advance :)

— 0