Restrict assignment in if statements in Typescript

Viewed 310

Recently I caught a nasty bug caused by assignment in If statement. I consider if-assignment as a bad pattern for me and I want to turn it off completely to get the compiler varnings instead of actual bugs.

How can I do this in Typescript?

1 Answers
Related