Why I no longer use #typescript with #react and why you shouldn’t either
▻https://hackernoon.com/why-i-no-longer-use-typescript-with-react-and-why-you-shouldnt-either-e7
Don’t get me wrong, I absolutely love TypeScript. #javascript code can get messy, and strict type checking has saved me countless hours of debugging. However, there are two main reasons why I don’t use it in my react apps and I’ll get into that soon.Why we use TypeScriptThere are quite a few great benefits of using TypeScript, especially:Instant type error detectionBetter IDE experienceMore self-documenting codeMore readable & easier to understandHowever, this comes at a cost. TypeScript, requires much more time to compile. Let’s take React as an example. I set up the default create-react-app project with and without typescript (for typescript, I usednpx create-react-app my-app —typescript ). The difference?Benchmarked on i5 7200UTo me, the time taken to create the project and the (...)