Tag: code-quality

React: bad practices

"There's more than one way to skin a cat." - this saying also applies to React projects. The same user interface can be built using different approaches to code. However, some of these approaches are worse than the others. Let's take a look at a few things to avoid in React projects.
Read more...

Opaque types in TypeScript

Have you ever called a multi-argument function with arguments in the wrong order? TypeScript does a great job of preventing that from happening - as long as arguments have incompatible types. But can we make TypeScript warn us about this kind of mistakes if, for instance, all arguments are numbers? In other words: if numbers were fruits, can TypeScript know the difference between apples and oranges?
Read more...