Comment by BigJono

5 years ago

Yeah, I'd be on board with that if 99% of the people talking about typed languages at the moment weren't using Typescript for use cases where you literally get instant feedback from hot reloading as you code.

Every time I see an example of a bug that TS would solve, it's something that I routinely find in 2 seconds by looking 10 degrees to the left at my second monitor and noticing the screen is white and there's some red text in the dev tools. "Compile time" doesn't mean anything if it consistently happens 0.5s before "run time".

As your application gets larger it's not that easy. Even if your code hot reloads all the time, getting to the piece of code that breaks might take 10 clicks or you are working on some feature that has quite a few combinations for use and/or settings that influence it. Maybe some feature flags thrown in. With this setting off and that feature flag on, suddenly your integer is a string. Boom runtime error but only because your QA thought of it when testing it 3 days after you already moved on to another ticket.